Open vczyh opened 2 months ago
Could you post a minimal example that reproduces it? it should be possible, ex i use readline for fq and this works:
$ fq -i
null> {a:{b:123}} | .<tab><tab><tab>
# end up with
null> {a:{b:123}} | .a.b
BTW you might want to consider using https://github.com/ergochat/readline that is more active fork.
Could you post a minimal example that reproduces it? it should be possible, ex i use readline for fq and this works:
$ fq -i null> {a:{b:123}} | .<tab><tab><tab> # end up with null> {a:{b:123}} | .a.b
BTW you might want to consider using https://github.com/ergochat/readline that is more active fork.
fq custom AutoCompleter
: https://github.com/wader/fq/blob/f150085735e8c20b86fa68210ed4162a3b6177b3/pkg/interp/interp.go#L458-L498
Yeap ends up being used here https://github.com/wader/fq/blob/f150085735e8c20b86fa68210ed4162a3b6177b3/pkg/cli/cli.go#L200-L212
What do you use now? something like PrefixCompleter
? that one seems to append whitespaces in some cases. Is there some reason you can't do your own AutoCompleter
?
Yeap ends up being used here https://github.com/wader/fq/blob/f150085735e8c20b86fa68210ed4162a3b6177b3/pkg/cli/cli.go#L200-L212
What do you use now? something like
PrefixCompleter
? that one seems to append whitespaces in some cases. Is there some reason you can't do your ownAutoCompleter
?
You're right. I need to implement my own AtutoCompleter. Thank you bro, I love you.
Happy it helped 👍
I know the result is right. Every autocompletion will add space.
I want:
What should I do?
Thanks!