()
| 30 | ) |
| 31 | |
| 32 | func ghMain() int { |
| 33 | if repositoryCreationIsManaged(os.Args[1:], os.Getenv("GH_ACCEPTANCE_FIXTURE_MODE")) { |
| 34 | fmt.Fprintln(os.Stderr, "gh repo create requires 'fixture-repo none'") |
| 35 | return 1 |
| 36 | } |
| 37 | return int(ghcmd.Main()) |
| 38 | } |
| 39 | |
| 40 | func repositoryCreationIsManaged(args []string, fixtureMode string) bool { |
| 41 | return len(args) > 1 && args[0] == "repo" && args[1] == "create" && fixtureMode != "none" |
nothing calls this directly
no test coverage detected