Commit graph

596 commits

Author SHA1 Message Date
James Stronz
22fa683571
CVE-2022-35861: Fixed relative path traversal due to using version string in path (#2412) 2022-07-17 01:01:04 +03:00
Pedro Fonini
fdaeaf1f97
Use version sort in pyenv versions if available (#2405) 2022-07-10 23:00:51 +03:00
Ivan Pozdeev
304515f2cd 2.3.2 2022-06-30 16:04:22 +03:00
Ivan Pozdeev
8ff6507f80 2.3.1 2022-05-29 19:50:13 +03:00
native-api
e676fde990
Fix endless loop in pyenv init - under SSH in some shell setups (#2374) 2022-05-18 16:15:05 +03:00
SADIK KUZU
169321b3e6
README.md, CHANGELOG.md, libexec/pyenv-help: Fix typos 2022-05-08 09:46:47 +03:00
Ville Skyttä
c3fd96c429
Version file read improvements (#2269)
* Don't bother reading empty version files
* Implement version file read in pure bash
Is faster with usual sized version files, slower with degenerate cases.
2022-05-06 19:51:51 +03:00
Ivan Pozdeev
2fd7be0453 2.3.0 2022-05-04 03:30:52 +03:00
Ivan Pozdeev
6d4365a696 Make pyenv init --path usable as a pyenv init - substitute
We're going to eliminate the need to mandatorily use `pyenv init --path`.
We can't delete it yet for backward compatibility.
Besides, there's one other use case for it: to enable shims but without
shell integration, e.g. for noninteractive shells.

To be a full-fledged replacement for `pyenv init -` however,
it needs to do rehashing.
2022-05-02 19:07:24 +03:00
Ivan Pozdeev
8439f8e187 Simplify init scheme; update & clarify the README
Now the setup is to add to both rc and profile:
1) set PYENV_ROOT
   (can do it unconditionally -- since if you change it,
   you need to update all places anyway since any of them can be run first)
2) Add `pyenv` to PATH if not already there
3) eval "$(pyenv init -)"

Not a breaking change, old setup will continue to work.
2022-05-02 19:07:24 +03:00
Josh Friend
3a95c969e1
v2.2.5 Add new CPython versions 2022-03-16 16:58:43 -04:00
Ville Skyttä
ee6ef20859
docs(pyenv-prefix): note support for multiple versions (#2270) 2022-03-09 05:33:01 +03:00
Anton Petrov
6f7a29c3f4
Update pyenv---version 2022-01-27 18:46:17 +03:00
Anton Petrov
8675031879
Update pyenv---version 2021-12-22 09:48:21 +03:00
Anton Petrov
dc3a201301
Update pyenv---version 2021-11-22 22:33:10 +03:00
Josh Friend
23dfe75b73
v2.2.1 2021-11-20 09:04:59 -05:00
Oğuzhan Çelikarslan
552d943762
Fix typos in command examples (#2147) 2021-11-09 09:50:29 +03:00
Anton Petrov
066c05336f
Update pyenv---version 2021-10-27 11:15:57 +03:00
Anton Petrov
05ca057bb2
Update pyenv---version 2021-10-05 17:32:37 +03:00
Ivan Pozdeev
e28661c7e2 Fix random "broken pipe" 2021-09-21 07:43:58 +03:00
Anton Petrov
dcfd715603
Update pyenv---version 2021-09-20 20:08:06 +03:00
Ivan Pozdeev
eb89256f59 Remove the sample code from pyenv init
since there proved to be to many cases to fit
2021-09-19 00:27:03 +03:00
native-api
4f689cdf83
Allow system Python in sbin (#2065)
Arch Linux has Python is sbin as well as bin
2021-09-15 20:00:49 +03:00
Pamela McA'Nulty
1c90a0f864
Prevent duplicate PATH entries when bin_path/.. is the same as PYENV_ROOT (#2045) 2021-09-15 01:09:50 +03:00
Anton Petrov
2d64fb1cb9
Update pyenv---version 2021-08-31 08:44:12 +03:00
Anton Petrov
e9c8dfc197
Update pyenv---version 2021-08-23 10:34:26 +03:00
Anton Petrov
cef86ce462
Update pyenv---version 2021-07-25 11:54:16 +03:00
Anton Petrov
3a5a21ee05
Update pyenv---version 2021-07-03 10:10:58 +03:00
native-api
f7754ae6a4
Remove PATH warning (#2001)
* In some cases (Ubuntu), `pyenv init -` has to be run before `pyenv init --path`.
* The warning has served its purpose by now.
2021-07-03 09:48:13 +03:00
Anton Petrov
20df064204
Update pyenv---version 2021-06-27 11:25:53 +03:00
Hugh Rawlinson
d2bd4c06ef
Suggest that fish users init in interactive mode
...rather than login mode.

I couldn't get rid of the warning that `pyenv init -` no longer sets path until I did this. It looks like setting only on the login shell wasn't enough to hide the warning in other shells I opened. This fits with [how rbenv does the same thing](https://github.com/rbenv/rbenv/blob/master/libexec/rbenv-init#L74).

I'm way out of my depth here, so someone who knows about shell types should definitely review this.
2021-06-27 00:22:59 +02:00
native-api
859b260764
Check for shims in path with pure Bash (#1978)
Closes https://github.com/pyenv/pyenv/issues/1921
2021-06-10 03:51:59 +03:00
Anton Petrov
f81bffc95e
2.0.1 2021-06-06 16:25:48 +03:00
Anton Petrov
1270ca6b0b
2.0.0 2021-05-23 20:01:43 +03:00
Anton Petrov
4ce52bd333
2.0.0-rc1 2021-05-20 23:20:22 +03:00
Ivan Pozdeev
ddf952ab2d Allow for cases where user might've aliased some programs
The $(type -p | head -1) construct expects to always get a path, so need to ignore such aliases with -P

Closes https://github.com/pyenv/pyenv/issues/1662
2021-05-17 10:48:46 +03:00
Ivan Pozdeev
e0d109c227 Include a Bash automated install option 2021-05-13 22:58:07 +03:00
native-api
0d07cda969
Update install instructions for Bash and Zsh (#1920)
* Update install instructions for Bash and Zsh

* Synchronize README.md with `pyenv init`
* Add a ~/.bash_profile note
* Concatenate shims activation into installation for brevity
  (Pyenv can't be used meaningfully without shims anyway)
  Otherwise, we'd need to duplicate all the ~/.profile shenanigans in both sections
* Update based on feedback
* Proofread
2021-05-13 22:57:14 +03:00
Fabian Homborg
0d2fb35cee
Fix fish installation instructions (#1916) 2021-05-11 22:35:15 +03:00
Ivan Pozdeev
da9392fd09 Add a hint for cases when ~/.profile sources ~/.rc
Our ~/.rc logic must run after the ~/.profile one
2021-05-10 04:39:45 +03:00
Ivan Pozdeev
13deda8875 Place full shell configuration instructions into pyenv init
including initial PATH and PYENV_ROOT entries.
The migration hint proved to be unclear to users without them.
2021-05-10 00:08:46 +03:00
Ivan Pozdeev
aab562c696 Add a warning about needing to restart the entire login session
E.g. for a GUI session, ~/.profile is executed by the GUI login "shell" at its startup
so one needs to fully log out and log back in.
Before that, the change would only be seen by shells explicitly started as login shells.
2021-05-07 16:21:17 +03:00
Ivan Pozdeev
3e3f40fefc Warn users to add pyenv init --path to ~/.profile
To facilitate migration
2021-05-05 03:04:52 +03:00
Ivan Pozdeev
7838707595 Separate startup logic into PATH and the rest
PATH manipulation should be done in ~/.profile rather than ~/.*rc since .rc can be sourced multiple times
2021-05-05 03:04:51 +03:00
Ivan Pozdeev
5998f4f7ab Refactoring: make logic more fit for rearrangement
With functions, we have more leeway in what to call
2021-05-05 01:25:11 +03:00
Anton Petrov
6656066d4f
1.2.27 2021-05-01 08:41:27 +03:00
Anton Petrov
2924886a77
Merge pull request #1350 from maxbrunet/feature/versions/dotglob
List versions starting with a dot
2021-04-15 21:02:50 +03:00
Ville Skyttä
641916270b feat: support (skip) commented lines in version-file
Sometimes it is convenient to be able to temporarily disable something
in a version-file. Because these files often aren't necessarily tracked
in a SCM, especially when working with virtualenvs, the SCM diffs won't
help with showing removed lines which are currently the only way to
disable something.
2021-04-11 07:46:34 +03:00
Anton Petrov
80067632b6
1.2.26 2021-04-05 14:25:25 +03:00
Anton Petrov
35aa7e52ce
1.2.25 2021-04-04 14:42:16 +03:00