global option
change -g by —location=global
This commit is contained in:
@@ -258,7 +258,7 @@ if [ "$display_info" = true ]; then
|
|||||||
fi
|
fi
|
||||||
done <<< "$lg"
|
done <<< "$lg"
|
||||||
else
|
else
|
||||||
npm list -g --depth=0
|
npm list --location=global --depth=0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo -e "$x"
|
echo -e "$x"
|
||||||
@@ -296,10 +296,10 @@ if [ -n "$glong_outdated" ]; then
|
|||||||
# /test
|
# /test
|
||||||
|
|
||||||
if [ "$no_distract" = false ]; then
|
if [ "$no_distract" = false ]; then
|
||||||
echo "$outdated" | xargs -p -n 1 npm -g install
|
echo "$outdated" | xargs -p -n 1 npm --location=global install
|
||||||
echo ""
|
echo ""
|
||||||
else
|
else
|
||||||
echo "$outdated" | xargs -n 1 npm -g install
|
echo "$outdated" | xargs -n 1 npm --location=global install
|
||||||
echo ""
|
echo ""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -353,7 +353,7 @@ if [ "$doctor" = true ]; then
|
|||||||
echo -e "\n${bold}Updating node to v$new_node...${reset}"
|
echo -e "\n${bold}Updating node to v$new_node...${reset}"
|
||||||
nvm install $new_node
|
nvm install $new_node
|
||||||
echo -e "\n${bold}Updating npm...${reset}"
|
echo -e "\n${bold}Updating npm...${reset}"
|
||||||
npm -g install npm
|
npm --location=global install npm
|
||||||
#
|
#
|
||||||
nvm use $new_node
|
nvm use $new_node
|
||||||
echo -e "\n${bold}Reinstall packages from $old_node...${reset}"
|
echo -e "\n${bold}Reinstall packages from $old_node...${reset}"
|
||||||
@@ -369,7 +369,7 @@ if [ "$doctor" = true ]; then
|
|||||||
|
|
||||||
if [ "$new_npm" != "$old_npm" ]; then
|
if [ "$new_npm" != "$old_npm" ]; then
|
||||||
echo -e "${underline}Udpate available for npm.${reset} You should run:"
|
echo -e "${underline}Udpate available for npm.${reset} You should run:"
|
||||||
echo -e " - ${bold}nnpm -g install npm${reset}"
|
echo -e " - ${bold}npm --location=global install npm${reset}"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ user=""
|
|||||||
# Add module to the do_not_update array for prevent to update.
|
# Add module to the do_not_update array for prevent to update.
|
||||||
#declare -a do_not_update=()
|
#declare -a do_not_update=()
|
||||||
#declare -a do_not_update=("parso" "asgiref")
|
#declare -a do_not_update=("parso" "asgiref")
|
||||||
declare -a do_not_update=("starlette")
|
declare -a do_not_update=("charset-normalizer")
|
||||||
#
|
#
|
||||||
#########################################
|
#########################################
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user