Closed segevfiner closed 6 years ago
It doesn't seem to change the behavior here. Would you have an example that I can test?
It doesn't seem to change the behavior here. Would you have an example that I can test?
#!/usr/bin/env python
import click
import click_completion
click_completion.init()
@click.command()
@click.argument("name-file", type=click.File("r"))
def f(name_file):
print "Hello, {}!".format(name_file.read())
if __name__ == "__main__":
f()
➜ eval "$(_HELLO_COMPLETE=source-zsh hello)"
➜ hello <tab><tab><tab> # Nothing... sigh...
➜ eval "$(_HELLO_COMPLETE=source-zsh hello)"
➜ hello <tab>
# File names are suggested
Which is what -o default
does in Bash, suggesting file names if no completions are generated.
ok, works for me too — I just had the wrong version tested…
thanks!
This is similar to Bash's
-o default
that is currently used.