diff options
| author | Jeff Carr <[email protected]> | 2025-09-25 01:30:05 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-09-25 01:30:05 -0500 |
| commit | 007d320fc9d73b90d515303a8429a558deb3dec4 (patch) | |
| tree | e2f9b4015e6d6df4bf082197de47c9052ded23b2 /argv.go | |
| parent | bafdfb766d0a43bbea38ee568be109d7d40d6628 (diff) | |
fix argv build
Diffstat (limited to 'argv.go')
| -rw-r--r-- | argv.go | 25 |
1 files changed, 15 insertions, 10 deletions
@@ -1,8 +1,9 @@ package main import ( - "fmt" "os" + + "go.wit.com/lib/gui/prep" ) /* @@ -41,15 +42,19 @@ go-mod-clean will try to verify your go.* files are using the newest package ver ` } -func (a args) DoAutoComplete(argv []string) { - switch argv[0] { - case "checkout": - fmt.Println("user devel master ") - default: - if argv[0] == ARGNAME { - // list the subcommands here - fmt.Println("strict restore purge lax") - } +/* + handles shell autocomplete +*/ + +func (args) Appname() string { + return ARGNAME +} + +func (a args) DoAutoComplete(pb *prep.Auto) { + if pb.Cmd == "" { + pb.Autocomplete3([]string{"strict", "--restore", "purge", "lax"}) + } else { + pb.SubCommand(pb.Argv...) } os.Exit(0) } |
