diff options
Diffstat (limited to 'sendStrings.go')
| -rw-r--r-- | sendStrings.go | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sendStrings.go b/sendStrings.go index 98ab7fa..546746d 100644 --- a/sendStrings.go +++ b/sendStrings.go @@ -1,4 +1,4 @@ -package prep +package argvpb // sends the autocomplete strings to the shell // also where custom strings are pulled in from the application @@ -13,22 +13,22 @@ import ( ) // deprecate -func (pb *Auto) Autocomplete3(sendthis []string) { +func (pb *Argv) Autocomplete3(sendthis []string) { pb.SendStrings(sendthis) } // deprecate -func (pb *Auto) Autocomplete2(sendthis string) { +func (pb *Argv) Autocomplete2(sendthis string) { pb.SendStrings(strings.Split(sendthis, " ")) } // the application must send a string "help run list" -func (pb *Auto) SendString(sendthis string) { +func (pb *Argv) SendString(sendthis string) { pb.SendStrings(strings.Split(sendthis, " ")) } // the application must send an array []string{"help", "run", "list"} -func (pb *Auto) SendStrings(parts []string) { +func (pb *Argv) SendStrings(parts []string) { /* dur := pb.Duration.AsDuration() if dur < time.Millisecond*200 { @@ -79,11 +79,11 @@ func (pb *Auto) SendStrings(parts []string) { } // try out a new name. also, this whole thing is dumb and needs to be redone -func (pb *Auto) GenerateSubCommandStrings(cmd ...string) { +func (pb *Argv) GenerateSubCommandStrings(cmd ...string) { pb.SubCommand(cmd...) } -func (pb *Auto) SubCommand(cmd ...string) { +func (pb *Argv) SubCommand(cmd ...string) { partial := strings.Trim(pb.Partial, "'") if pb.Debug { if me.examples == nil { |
