From 9bae0347192b91687d9edf6ffac7e3818a579848 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cyryl=20P=C5=82otnicki?= Date: Thu, 3 Nov 2016 20:55:20 +0100 Subject: [PATCH] Fix pip detection --- common/configure_fresh_system | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/common/configure_fresh_system b/common/configure_fresh_system index d6e2a2c9..5695a7a6 100755 --- a/common/configure_fresh_system +++ b/common/configure_fresh_system @@ -170,16 +170,21 @@ $SUDO npm install -g reveal-md echo "Installing fancy differ" $SUDO npm install -g diff-so-fancy -pip3_path=`which pip3` -if [[ -z $NOPYTHON3 && -x pip3_path ]]; then - PIP=pip3 -else - PIP=pip +if [[ -z $NOPYTHON3 ]]; then + pip3_path=`which pip3` + echo "pip3 path is $pip3_path" + if [[ -x pip3_path ]]; then + echo "Choosing pip3 for pip" + PIP=pip3 + else + echo "Choosing pip" + PIP=pip + fi + echo "Installing Nikola" + $SUDO $PIP install pygments-style-solarized ws4py watchdog webassets Nikola + fi fi -echo "Installing Nikola" -$SUDO $PIP install pygments-style-solarized ws4py watchdog webassets Nikola - if [[ -z $USER ]]; then USER=`whoami` fi