From 1d63be0506e70cd9ab36c4ea8f9f6478a09a8422 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 7 Nov 2019 13:51:51 -0800 Subject: [PATCH] Reduce duplicate in pipeline, cache in release job --- azure-pipelines.yml | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 1ee66ddb..4daa0961 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -87,19 +87,12 @@ jobs: inputs: versionSpec: '8.x' displayName: 'Install Node.js' - - task: CacheBeta@1 - inputs: - key: yarn_puppeteer | $(Agent.OS) | yarn.lock - path: node_modules - displayName: Cache node modules - task: YarnInstaller@3 inputs: versionSpec: '1.x' displayName: 'Install Yarn' - script: yarn --frozen-lockfile displayName: 'Install dependencies and build' - - script: yarn add puppeteer - displayName: 'Install puppeteer' - script: | yarn start & sleep 10 @@ -116,8 +109,6 @@ jobs: displayName: 'Install Node.js' - script: yarn --frozen-lockfile displayName: 'Install dependencies and build' - - script: yarn add puppeteer - displayName: 'Install puppeteer' - script: | yarn start & sleep 10 @@ -143,6 +134,10 @@ jobs: inputs: versionSpec: '1.x' displayName: 'Install Yarn' + - task: CacheBeta@1 + inputs: + key: yarn2 | $(Agent.OS) | yarn.lock + path: node_modules - script: yarn --frozen-lockfile displayName: 'Install dependencies and build' - script: NPM_AUTH_TOKEN="$(NPM_AUTH_TOKEN)" node ./bin/publish.js