1
0
mirror of https://github.com/pyenv/pyenv.git synced 2025-11-17 15:53:45 -05:00

Add --no-push-path option (#2526)

In some advanced shell setups, the order of custom-added PATH entries is important.
We disregard it by default, always pushing shims to the front of PATH,
to ensure that Pyenv works even in poorly maintained shell environments
and with minimal hassle for non-export users
(an attempt to do the opposite (#1898) has ended in a disaster).
Some advanced users are however ready and able to carefully maintain their environment
and deal with breakages and inconvenience. This option is for them.
This commit is contained in:
Isaac Levy
2022-11-18 16:01:59 -05:00
committed by GitHub
parent 4c261e6ea1
commit cc56f76733
3 changed files with 104 additions and 25 deletions

View File

@@ -386,11 +386,12 @@ List existing pyenv shims.
Configure the shell environment for pyenv
Usage: eval "$(pyenv init [-|--path] [--no-rehash] [<shell>])"
Usage: eval "$(pyenv init [-|--path] [--no-push-path] [--no-rehash] [<shell>])"
- Initialize shims directory, print PYENV_SHELL variable, completions path
and shell function
--path Print shims path
--no-push-path Do not push shim to the start of PATH if they're already there
--no-rehash Add no rehash command to output
## `pyenv completions`