-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
output shell completion script by bat --completion <shell>
command
#2057
Comments
The bash completion should be placed in this
For system wide installation (e.g. packaging deb, ...) the completion may be placed in |
@abuGit - I don't think you understand my feature request. I am asking for a completion script built-in from Yes, |
I would really like this, too, for |
I haven't figured out a good way to get the completions when installing |
This worked for me: TARGET_DIR=tmp
CMP_SCRIPT=bat.bash
mkdir -p $TARGET_DIR
cargo install --locked --target-dir $TARGET_DIR bat
mkdir -p ~/.local/share/bash-completion/completions
cp $(find $TARGET_DIR -name $CMP_SCRIPT) ~/.local/share/bash-completion/completions/ Edit: Actually this method looks cleaner/easier. |
Currently the autocompletion script comes only with the source.
A better approach, would be something like
bat --completion=bash
.Here is my current
bash_completion
script executed at login:The text was updated successfully, but these errors were encountered: