From 43d3dbde2c6a83092bbbd06344d56e85c8c5fb7c Mon Sep 17 00:00:00 2001 From: cat_shark <1716967236@qq.com> Date: Sat, 30 May 2026 09:42:23 +0800 Subject: [PATCH] =?UTF-8?q?Revert=20"=E4=BF=AE=E5=A4=8D=EF=BC=9A=E7=A7=BB?= =?UTF-8?q?=E9=99=A4=20.npm=20=E5=8D=B7=E6=8C=82=E8=BD=BD=EF=BC=8C?= =?UTF-8?q?=E8=A7=A3=E5=86=B3=20npm=20=E7=BC=93=E5=AD=98=E6=9D=83=E9=99=90?= =?UTF-8?q?=E9=97=AE=E9=A2=98"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This reverts commit 2da736aaf394b20a154890cb021b24512335924b. --- Jenkinsfile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index d4e4a61..c4672f5 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -10,11 +10,13 @@ pipeline { agent { docker { image 'node:20-alpine' - args '-v ${WORKSPACE}/node_modules:/app/node_modules' + args '-u root -v ${WORKSPACE}/.npm:/.npm -v ${WORKSPACE}/node_modules:/app/node_modules' } } steps { sh ''' + npm config set cache /.npm + chown -R $(id -u):$(id -g) /.npm 2>/dev/null || true npm install ''' } @@ -24,11 +26,12 @@ pipeline { agent { docker { image 'node:20-alpine' - args '-v ${WORKSPACE}/node_modules:/app/node_modules' + args '-u root -v ${WORKSPACE}/.npm:/.npm -v ${WORKSPACE}/node_modules:/app/node_modules' } } steps { sh ''' + chown -R $(id -u):$(id -g) /.npm 2>/dev/null || true npm run type-check npm run build '''