install: attempt to make pnpm consistent with package.json packageManager whether or not corepack is present

This commit is contained in:
Aminda Suomalainen 2024-08-07 08:34:52 +03:00
parent 7174c79d4a
commit 2a0117b7f1
Signed by: Mikaela
SSH Key Fingerprint: SHA256:CXLULpqNBdUKB6E6fLA1b/4SzG0HvKD19PbIePU175Q

View File

@ -64,6 +64,9 @@ fi
if hash corepack 2> /dev/null; then
corepack enable --install-directory ~/.local/bin/
corepack enable npm --install-directory ~/.local/bin/
corepack pnpm config set manage-package-manager-versions=true
elif hash pnpm 2> /dev/null; then
pnpm config set manage-package-manager-versions=true
else
echo "WARNING! corepack is not installed."
sleep 3