diff options
| author | Jeff Carr <[email protected]> | 2025-10-13 09:53:15 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-10-13 09:53:15 -0500 |
| commit | d4b928f7bb8f66afc31a95fa4552b8fd8fba3712 (patch) | |
| tree | 689a40f652bd2f784eb1e028340282bdb2f5739b /theMagicOfAutocomplete.go | |
| parent | 915ea4f648f8639cb1fc4111fa49ff298ea79441 (diff) | |
calls back to the apps' main/argv.go but what next?
Diffstat (limited to 'theMagicOfAutocomplete.go')
| -rw-r--r-- | theMagicOfAutocomplete.go | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/theMagicOfAutocomplete.go b/theMagicOfAutocomplete.go index 942bd24..21aebed 100644 --- a/theMagicOfAutocomplete.go +++ b/theMagicOfAutocomplete.go @@ -18,6 +18,14 @@ func Autocomplete(dest any) *Auto { myAuto = new(AutoArgs) // todo: redo this findAppInfo(dest) // parses back to main() for argv info + if myAuto.guiFunc != nil { + // register gui args + myAuto.guiFunc() + // log.Info("gui init") + } else { + // log.Info("no gui init") + } + // load the argv history from the protobuf file all := NewAutos() err := config.LoadCache(all, "argv", myAuto.appName) // loads ~/.cache/argv/forge.pb @@ -32,7 +40,7 @@ func Autocomplete(dest any) *Auto { // try to register bash args for go-args arg.Register(&argBash) - arg.Register(&argGui) + // arg.Register(&argGui) // user is trying to setup bash or zsh autocomplete // --bash or --zsh is the first os.Args |
