diff options
| author | Jeff Carr <[email protected]> | 2025-01-28 17:03:56 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-01-28 17:03:56 -0600 |
| commit | 51ec39d1579c6bd89d6c5c38a1ff2879c37d3d03 (patch) | |
| tree | ee793a1a3c0e909e200e145a5e8a59587b81ea1a /main.go | |
| parent | 7402aaded7b9f9587eb5ba863b732c9c9e8ee9fe (diff) | |
cleanup argv handling. go-arg saves the day
Diffstat (limited to 'main.go')
| -rw-r--r-- | main.go | 31 |
1 files changed, 13 insertions, 18 deletions
@@ -79,6 +79,18 @@ func main() { } if argv.Clean != nil { + if argv.Clean.Examine != nil { + if err := doExamine(); err != nil { + badExit(err) + } + okExit("") + } + if argv.Clean.GitReset != nil { + findAll() // select all the repos + doGitReset() + okExit("reset") + } + if err := doClean(); err != nil { badExit(err) } @@ -90,18 +102,6 @@ func main() { okExit("") } - if argv.Examine != nil { - if err := doExamine(); err != nil { - badExit(err) - } - okExit("") - } - - if argv.Rescan != nil { - me.forge.ScanGoSrc() - okExit("") - } - if argv.Show != "" { repo := me.forge.FindByGoPath(argv.Show) me.forge.HumanPrintRepo(repo) @@ -131,18 +131,13 @@ func main() { okExit("") } - if argv.GitReset != nil { - findAll() // select all the repos - doGitReset() - okExit("reset") - } - if argv.List != nil { argv.List.findRepos() // print out the repos me.forge.PrintHumanTable(me.found) okExit("") } + if argv.Patch != nil { if argv.Patch.Submit != "" { doSubmit(argv.Patch.Submit) |
