Skip to content

Commit

Permalink
simplifying the uninstall of pnpm
Browse files Browse the repository at this point in the history
  • Loading branch information
ramykl committed Dec 27, 2023
1 parent 29b8e8a commit 4d94e4d
Showing 1 changed file with 1 addition and 14 deletions.
15 changes: 1 addition & 14 deletions src/scripts/install-pnpm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,22 +21,9 @@ installation_check () {
else
echo "A different version of pnpm is installed ($(pnpm --version)); removing it"

if uname -a | grep Darwin > /dev/null 2>&1; then
brew uninstall pnpm > /dev/null 2>&1
elif grep Alpine /etc/issue > /dev/null 2>&1; then
apk del pnpm > /dev/null 2>&1
elif grep Debian /etc/issue > /dev/null 2>&1; then
$SUDO apt-get remove pnpm > /dev/null 2>&1 && \
$SUDO apt-get purge pnpm > /dev/null 2>&1
elif grep Ubuntu /etc/issue > /dev/null 2>&1; then
$SUDO apt-get remove pnpm > /dev/null 2>&1 && \
$SUDO apt-get purge pnpm > /dev/null 2>&1
elif command -v yum > /dev/null 2>&1; then
yum remove pnpm > /dev/null 2>&1
fi

$SUDO rm -rf "$(pnpm store path)" > /dev/null 2>&1
$SUDO rm -rf $PNPM_HOME > /dev/null 2>&1
$SUDO npm rm -g pnpm > /dev/null 2>&1
fi
fi
}
Expand Down

0 comments on commit 4d94e4d

Please sign in to comment.