kislyuk / argcomplete

Python and tab completion, better together.
https://kislyuk.github.io/argcomplete/
Apache License 2.0
1.39k stars 129 forks source link

Add new option to activate-global-python-argcomplete that returns location of bash completion script #364

Open xcl-gh opened 2 years ago

xcl-gh commented 2 years ago

It would be nice for activate-global-python-argcomplete to have an option that returns the location of the bash completion script. This would help in situations where we can't/don't want to use activate-global-python-argcomplete to make a copy of the completion script and want to source the script directly from the package.

flu0r1ne commented 1 year ago

This is an intriguing and practical idea. The advantage of having the completion script update automatically alongside the package is that it allows bugs to be addressed retrospectively, without requiring user intervention. This proactive approach would ensure smoother operation and mitigating the impact of any potential issues.

Furthermore, this idea addresses another issue I've noted: the --user installation on the zsh shell currently prompts users to select a directory from their $fpath for placing the completion script. This can be problematic as, often, there isn't a user directory intended for this purpose. Implementing this solution could offer a way to perform a true user installation.

If this proposal resonates, I'd be glad to investigate this further. @kislyuk