Skip to content

Commit

Permalink
cache template
Browse files Browse the repository at this point in the history
  • Loading branch information
aminya committed Jul 11, 2020
1 parent fc4dc84 commit ca37fcf
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions script/vsts/platforms/cache.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
parameters:
- name: OS
displayName: Operating System
type: string
values:
- windows
- linux
- macos

steps:
- task: Cache@2
displayName: Cache node_modules
inputs:
key: 'npm | "$(Agent.OS)" | "$(buildArch)" | package.json, package-lock.json, script/vsts/platforms/{{ parameters.OS }}.yml'
path: 'node_modules'
cacheHitVar: MainNodeModulesRestored

- task: Cache@2
displayName: Cache script/node_modules
inputs:
key: 'npm | "$(Agent.OS)" | "$(buildArch)" | script/package.json, script/package-lock.json, script/vsts/platforms/{{ parameters.OS }}.yml'
path: 'script/node_modules'
cacheHitVar: ScriptNodeModulesRestored

- task: Cache@2
displayName: Cache apm/node_modules
inputs:
key: 'npm | "$(Agent.OS)" | "$(buildArch)" | apm/package.json, apm/package-lock.json, script/vsts/platforms/{{ parameters.OS }}.yml'
path: 'apm/node_modules'
cacheHitVar: ApmNodeModulesRestored

0 comments on commit ca37fcf

Please sign in to comment.