summaryrefslogtreecommitdiff
path: root/sendStrings.go
diff options
context:
space:
mode:
Diffstat (limited to 'sendStrings.go')
-rw-r--r--sendStrings.go7
1 files changed, 5 insertions, 2 deletions
diff --git a/sendStrings.go b/sendStrings.go
index 19ccc30..2fe1977 100644
--- a/sendStrings.go
+++ b/sendStrings.go
@@ -1,6 +1,8 @@
package prep
-// initializes logging and command line options
+// sends the autocomplete strings to the shell
+// also where custom strings are pulled in from the application
+// calls into go-args for strings parsed by MustParse()
import (
"fmt"
@@ -21,11 +23,12 @@ func (pb *Auto) Autocomplete2(sendthis string) {
pb.SendStrings(strings.Split(sendthis, " "))
}
+// the application must send a string "help run list"
func (pb *Auto) SendString(sendthis string) {
pb.SendStrings(strings.Split(sendthis, " "))
}
-// this is the user's application sending us strings we need to send to bash
+// the application must send an array []string{"help", "run", "list"}
func (pb *Auto) SendStrings(parts []string) {
dur := pb.Duration.AsDuration()
if dur < time.Millisecond*200 {