diff --git a/Jenkinsfile b/Jenkinsfile index 2048a36..f34d0e0 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -4,8 +4,8 @@ def deploy() { stage('Deploy (Ubuntu)') { checkout scm nodejs(nodeJSInstallationName: 'Node23') { - sh 'npm ci --include=dev' - sh 'npm run build' + sh 'yarn install --frozen-lockfile' + sh 'yarn build' // Deploy to Cloudflare Pages using wrangler // CLOUDFLARE_API_TOKEN should be set as a Jenkins credential/env variable sh 'npx wrangler pages deploy build' @@ -30,10 +30,10 @@ def buildOnLabel(label, buildCommand) { nodejs(nodeJSInstallationName: 'Node23') { if (isUnix()) { sh 'node -v' - sh 'npm -v' + sh 'yarn -v' } else { bat 'node -v' - bat 'npm -v' + bat 'yarn -v' } } } @@ -41,9 +41,9 @@ def buildOnLabel(label, buildCommand) { stage("Install Dependencies (${label})") { nodejs(nodeJSInstallationName: 'Node23') { if (isUnix()) { - sh 'npm ci --include=dev' + sh 'yarn install --frozen-lockfile' } else { - bat 'npm ci --include=dev' + bat 'yarn install --frozen-lockfile' } } } @@ -76,8 +76,8 @@ def buildOnLabel(label, buildCommand) { try { parallel( - 'Windows Build': buildOnLabel('windows', 'npm run build:electron'), - 'MacOS Build': buildOnLabel('macos', 'npm run build:electron'), + 'Windows Build': buildOnLabel('windows', 'yarn build:electron'), + 'MacOS Build': buildOnLabel('macos', 'yarn build:electron'), 'Ubuntu Deploy': { deploy() } )