REGISTER-PYTHON-ARGCOMPLETE(1)
π REGISTER-PYTHON-ARGCOMPLETE(1) π User Commands
β¨ NAME β¨
okay so register-python-argcomplete is the argcomplete module's utility script π it's literally the thing that makes tab completion work for your Python scripts π«Ά
π DESCRIPTION π
Here's the vibe. The usage line looks like this:
usage: register-python-argcomplete [-h] [--no-defaults]
[--complete-arguments ...]
[-s {bash,zsh,tcsh,fish,powershell}] [-e
EXTERNAL_ARGCOMPLETE_SCRIPT] executable [executable ...]
Its whole job is to register a Python executable so the argcomplete module can handle its completions π₯
To actually register it, you source the output of this script in your bash shell π and make sure you quote the output so nothing gets interpolated weirdly π
Example:
$ eval "$(register-python-argcomplete my-favorite-script.py)"
For Tcsh πΈ
$ eval `register-python-argcomplete --shell tcsh my-favorite-
script.py`
For Fish π
$ register-python-argcomplete --shell fish my-favourite-script.py
> ~/.config/fish/my-favourite-script.py.fish
π§ positional arguments π§
executable
the executable you want to complete, but only when it gets invoked by exactly this name β¨
π options π
-h,--helpβ shows the help message and exits π--no-defaultsβ if no matches get generated, this stops it from falling back to readline's default completion π ββοΈ (bash only!)--complete-arguments ...β the arguments you want to pass tocomplete. heads up: using this option throws out the default options ποΈ (bash only!)-s {bash,zsh,tcsh,fish,powershell},--shell {bash,zsh,tcsh,fish,powershell}β outputs the code for whichever shell you pick π-e EXTERNAL_ARGCOMPLETE_SCRIPT,--external-argcomplete-script EXTERNAL_ARGCOMPLETE_SCRIPTβ points to an external argcomplete script that handles auto completion for the executable π¦
π AUTHORS π
the argcomplete module was written by Andrey Kislyuk π©βπ»β¨
π SEE ALSO π
the full documentation for the argccomplete module lives at https://argcomplete.readthedocs.org/en/latest/ π
bestie, that's the whole thing π₯Ήπ you're officially a register-python-argcomplete girlie now. this has been register-python-argcomplete 3... from November 2023, slay forever π π
π¦ where this page comes from
- debian trixie: python3-argcomplete 3.6.2-1 Β· Apache-2.0
- ubuntu noble: python3-argcomplete 3.1.4-1 Β· Apache-2.0
- ubuntu noble: python3-argcomplete 3.1.4-1ubuntu0.1 Β· Apache-2.0
- ubuntu questing: python3-argcomplete 3.6.2-1 Β· Apache-2.0
- ubuntu resolute: python3-argcomplete 3.6.3-1 Β· Apache-2.0
- ubuntu stonking: python3-argcomplete 3.7.0-1 Β· Apache-2.0
- π girlified by anthropic/claude-haiku-5.5 on : a language model's rewrite of the original, under its terms