tj / n

Node version management

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

n modules, it doesn't work, cannot download the index.tab or xz file

lk101 opened this issue · comments

commented

Bug Report

n works as it.
image

chrome works as it.
image

Summary

I configure the N_NODE_MIRROR in ~/.bashrc, but it still doesn't work.

export N_NODE_MIRROR=https://npmmirror.com/mirrors/node

Whatever I configure it or not, it does not work.

Environment

image

Configuration Details

$ n --version
v9.0.0

$ command -v node
/usr/local/bin/node

$ node -p process.platform
linux

From where I am, that custom mirror is slow but working. A command similar to what n uses internally to download the index is:

$ time curl --silent  --compressed --location --fail --show-error https://nodejs.org/dist/index.tab
... 0.269 total

$ time curl --silent --compressed --location --fail --show-error https://npmmirror.com/mirrors/node/index.tab
... 7.243 total

Do those commands fail for you with any additional information?

(That is just for the index, so downloading a version is much larger.)

commented

From where I am, that custom mirror is slow but working. A command similar to what n uses internally to download the index is:

$ time curl --silent  --compressed --location --fail --show-error https://nodejs.org/dist/index.tab
... 0.269 total

$ time curl --silent --compressed --location --fail --show-error https://npmmirror.com/mirrors/node/index.tab
... 7.243 total

Do those commands fail for you with any additional information?

(That is just for the index, so downloading a version is much larger.)

I'm not sure that. Must I install the curl ?
image

commented

It works after I install the curl, thanks very much.