File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -291,6 +291,16 @@ check_python_version() {
291291 fi
292292}
293293
294+ check_pip_version () {
295+ PYTHON_VERSION=` $PYTHON --version | awk ' {print $2}' | cut -d ' .' -f 1,2`
296+ PIP_PYTHON_VERSION=` $PIP --version | sed -nE ' s/.*\(python\s(.*)\)/\1/p' `
297+
298+ if [ " $PYTHON_VERSION " != " $PIP_PYTHON_VERSION " ]; then
299+ echo -e " \e[33mWarning: The installed $PIP comes from Python $PIP_PYTHON_VERSION while your"
300+ echo -e " Python interpreter has version $PYTHON_VERSION . This is likely to cause problems.\e[0m"
301+ fi
302+ }
303+
294304not_cached () {
295305 if [ ! -d .packages ]; then
296306 return 0
@@ -353,6 +363,7 @@ while [ "$1" != "" ]; do
353363done
354364
355365check_python_version
366+ check_pip_version
356367
357368MYPATH=" $( cd -- " $( dirname " $0 " ) " > /dev/null 2>&1 ; pwd -P ) "
358369cd " $MYPATH "
You can’t perform that action at this time.
0 commit comments