Adjust suggested shell startup code to support Pyenv with Pyenv-Win in WSL
There's a complaint that this results in duplicate PATH entries in nested shells, will deal with that separately
This commit is contained in:
parent
d04a081dcb
commit
1db48d317a
@ -189,7 +189,7 @@ See [Advanced configuration](#advanced-configuration) for details and more confi
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.bashrc
|
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.bashrc
|
||||||
echo 'command -v pyenv >/dev/null || export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.bashrc
|
echo '[[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.bashrc
|
||||||
echo 'eval "$(pyenv init -)"' >> ~/.bashrc
|
echo 'eval "$(pyenv init -)"' >> ~/.bashrc
|
||||||
```
|
```
|
||||||
3. Then, if you have `~/.profile`, `~/.bash_profile` or `~/.bash_login`, add the commands there as well.
|
3. Then, if you have `~/.profile`, `~/.bash_profile` or `~/.bash_login`, add the commands there as well.
|
||||||
@ -198,7 +198,7 @@ See [Advanced configuration](#advanced-configuration) for details and more confi
|
|||||||
* to add to `~/.profile`:
|
* to add to `~/.profile`:
|
||||||
``` bash
|
``` bash
|
||||||
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.profile
|
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.profile
|
||||||
echo 'command -v pyenv >/dev/null || export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.profile
|
echo '[[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.profile
|
||||||
echo 'eval "$(pyenv init -)"' >> ~/.profile
|
echo 'eval "$(pyenv init -)"' >> ~/.profile
|
||||||
```
|
```
|
||||||
* to add to `~/.bash_profile`:
|
* to add to `~/.bash_profile`:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user