Skip to content

Commit b1c16be

Browse files
committed
Set both npm_config_store_dir and pnpm_config_store_dir
pnpm <11 reads npm_config_*, pnpm 11+ reads pnpm_config_*. Set both to cover all versions without version detection.
1 parent 12ab032 commit b1c16be

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

bin/compile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,8 +204,9 @@ fi
204204
[ ! "$NPM_CONFIG_CACHE" ] && NPM_CONFIG_CACHE=$(mktemp -d -t npmcache.XXXXX)
205205
[ ! "$PNPM_CONFIG_CACHE" ] && PNPM_CONFIG_CACHE=$(mktemp -d -t pnpmcache.XXXXX)
206206
export YARN_CACHE_FOLDER NPM_CONFIG_CACHE PNPM_CONFIG_CACHE
207-
# npm_config_store_dir works across all pnpm versions (7.x – 11.x)
207+
# npm_config_store_dir works for pnpm <11, pnpm_config_store_dir for pnpm 11+
208208
export npm_config_store_dir="$PNPM_CONFIG_CACHE"
209+
export pnpm_config_store_dir="$PNPM_CONFIG_CACHE"
209210

210211
install_bins() {
211212
local node_engine npm_engine yarn_engine node_version package_manager pnpm_engine

0 commit comments

Comments
 (0)