Skip to content

Commit

Permalink
xdg: update npm prefix
Browse files Browse the repository at this point in the history
and cleanup some stale values

* `update-notifier` was dropped in v7: npm/cli@d062b2c
* `devdir` no longer defaults to ~/.node-gyp: nodejs/node-gyp@8a83972
* Some tools try to respect npm's cache dir but only read `npm_config_cache`
  • Loading branch information
branchvincent committed Jul 10, 2024
1 parent 3ab8d10 commit 2ce2863
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions .config/fish/conf.d/__xdg.fish
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,9 @@ set -gx LESSHISTFILE /dev/null

# node
set -gx NODE_REPL_HISTORY /dev/null
set -gx NO_UPDATE_NOTIFIER 1 # used by npm: https://github.com/yeoman/update-notifier/issues/180
set -gx NPM_CONFIG_CACHE $XDG_CACHE_HOME/npm
set -gx NPM_CONFIG_DEVDIR $XDG_DATA_HOME/node-gyp
set -gx NPM_CONFIG_INIT_MODULE $XDG_CONFIG_HOME/npm/config/npm-init.js
set -gx NPM_CONFIG_PREFIX $XDG_DATA_HOME/npm
set -gx NPM_CONFIG_USERCONFIG $XDG_CONFIG_HOME/npm/npmrc
set -p XDG_BIN_DIRS $NPM_CONFIG_PREFIX/bin
__maybe_mkdir $NPM_CONFIG_PREFIX/lib
set -gx npm_config_cache $XDG_CACHE_HOME/npm
set -gx npm_config_prefix ~/.local
set -gx npm_config_userconfig $XDG_CONFIG_HOME/npm/npmrc

# pip
set -gx PIP_CACHE_DIR $XDG_CACHE_HOME/pip
Expand Down

0 comments on commit 2ce2863

Please sign in to comment.