Skip to content
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

feat: add 3rd party generated completion fallbacks #905

Merged
merged 15 commits into from Mar 26, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion bash_completion
Expand Up @@ -2567,7 +2567,7 @@ __load_completion()
# Do not warn with . or .. (especially the former is common)
[[ $compfile == */.?(.) ]] ||
echo "bash_completion: $compfile: is a directory" >&2
elif [[ -e $compfile ]] && . "$compfile"; then
elif [[ -e $compfile ]] && . "$compfile" "$cmd"; then
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess this is something we could consider adding a test for, but I'm not sure if it's worth the trouble.

Also not sure about adding tests for the the actual completions as their result varies depending on if the generating command is installed or not.

[[ $backslash ]] && $(complete -p "$cmd") "\\$cmd"
return 0
fi
Expand Down