From 1eed4cc7ee70deb3eda5026db43007d00fe61929 Mon Sep 17 00:00:00 2001 From: TorchedSammy <38820196+TorchedSammy@users.noreply.github.com> Date: Tue, 30 Aug 2022 23:38:46 -0400 Subject: [PATCH] fix: add back empty string in command line split this fixes file completion in normal usage without using quotes. it basically cut out the space at the end which prevented normal usage without adding an additional space or using quotes for file completion --- complete.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/complete.go b/complete.go index 3a2899d..76d65f7 100644 --- a/complete.go +++ b/complete.go @@ -27,6 +27,9 @@ func splitQuote(str string) []string { sb.WriteRune(r) } } + if strings.HasSuffix(str, " ") { + split = append(split, "") + } if sb.Len() > 0 { split = append(split, sb.String())