From c683685e7e1e3373edc5ee161af5373be2a32109 Mon Sep 17 00:00:00 2001 From: undefined Date: Mon, 31 May 2021 16:26:46 +0800 Subject: [PATCH] install: use gitee nvm mirror --- install/install.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/install/install.js b/install/install.js index 76f6f0258..b7e710436 100644 --- a/install/install.js +++ b/install/install.js @@ -86,7 +86,9 @@ apt-get -qq update && apt-get -q install -y mongodb-org`, { retry: true }], operations: [ () => { const resp = http.request('GET', 'https://cdn.jsdelivr.net/gh/nvm-sh/nvm@v0.36.0/install.sh'); - const script = resp.body.replace(/raw\.githubusercontent\.com\/nvm-sh\/nvm\//g, 'cdn.jsdelivr.net/gh/nvm-sh/nvm@'); + const script = resp.body + .replace(/raw\.githubusercontent\.com\/nvm-sh\/nvm\//g, 'cdn.jsdelivr.net/gh/nvm-sh/nvm@') + .replace(/github\.com\/nvm-sh\/nvm\.git/g, 'gitee.com/imirror/nvm'); fs.writefile('/tmp/install-nvm.sh', script); }, 'bash /tmp/install-nvm.sh',