The mac virtual environment venv terminal cannot directly use the shortcut command pip #2631
-
Beta Was this translation helpful? Give feedback.
Answered by
gaborbernat
Aug 29, 2023
Replies: 2 comments 1 reply
-
Beta Was this translation helpful? Give feedback.
0 replies
-
I add this function in my pyvenv() {
envfolder=$1
if [ -z "$envfolder" ]; then
envfolder=.venv
fi
envdir=`pwd`/$envfolder &&
python -m venv $envdir &&
if [ -d "$envdir" ]; then
echo alias pip=$envdir/bin/pip >> $envdir/bin/activate &&
source $envdir/bin/activate &&
echo -e "\e[33m"$envdir"\e[0m" has been created as virtual environment!
return
fi
} Use |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
venv is not virtualenv, https://virtualenv.pypa.io/en/latest/user_guide.html#user-guide