-
-
Notifications
You must be signed in to change notification settings - Fork 8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR #1429
Comments
Sure, having both set is harmless, and nvm will indeed always set node-gyp is the only software I'm aware of that incorrectly depended on nvm's env vars - it no longer does, hence the warning. Are you suggesting that nvm add support for |
OK. In that case, perhaps the workaround should be: unset NVM_IOJS_ORG_MIRROR NVM_NODEJS_ORG_MIRROR I don't know how clever you want to make |
I guess a totally reasonable alternative would be, making |
defaults, fwiw, are super easy, and cross-shell-compatible. You'd just delete this: # Setup mirror location if not already set
if [ -z "${NVM_NODEJS_ORG_MIRROR-}" ]; then
export NVM_NODEJS_ORG_MIRROR="https://nodejs.org/dist"
fi
if [ -z "${NVM_IOJS_ORG_MIRROR-}" ]; then
export NVM_IOJS_ORG_MIRROR="https://iojs.org/dist"
fi and update nvm_get_mirror() {
case "${1}-${2}" in
node-std) nvm_echo "${NVM_NODEJS_ORG_MIRROR:-https://nodejs.org/dist}" ;;
iojs-std) nvm_echo "${NVM_IOJS_ORG_MIRROR:-https://iojs.org/dist}" ;;
*)
nvm_err 'unknown type of node.js or io.js release'
return 1
;;
esac
} (If this is reasonable I can give you a PR so you can goose your Contributors count) |
Thanks, that's totally reasonable, and just what I had in mind :-) Want to submit a PR (with unit test)? :-D |
omg hour builds I'm getting monorail flashbacks |
nvm debug
output:nvm ls
output:How did you install
nvm
?install script in readme
What steps did you perform?
Building native npm dependencies
What happened?
What did you expect to happen?
No warnings
Is there anything in any of your profile files (
.bashrc
,.bash_profile
,.zshrc
, etc) that modifies thePATH
?Yes, but that's irrelevant here.
¿por qué no los dos?
I don't know how many other systems look at these variables, so the safest (and most-chicken^H^H^H^H^H^Hconservative) solution would be to set both MIRROR values with and without the NPM prefix. The following, added to my
~/.bashrc
after the call tosource nvm.sh
, removes the node-gyp warning:FWIW, I didn't have to unset
NVM_NODEJS_ORG_MIRROR
. Having both set seems harmless.The text was updated successfully, but these errors were encountered: