configure cache in azure pipelines
@@ -39,6 +39,14 @@ jobs:
python -m gammapy info
displayName: 'Install Gammapy'
+ - task: Cache@2
+ inputs:
+ key: gammapy_data | $(Build.SourceVersion)
+ restoreKeys: |
+ gammapy_data | $(Build.SourceVersion)
+ path: $(GAMMAPY_DATA)
+ displayName: Cache GAMMAPY_DATA
+
- script: |
gammapy download datasets --out=$(GAMMAPY_DATA) --silent --tests
displayName: 'Get GAMMAPY_DATA'
@@ -75,6 +83,14 @@ jobs:
python -m gammapy info
displayName: 'Install Gammapy'
+ - task: Cache@2
+ inputs:
+ key: gammapy_data | $(Build.SourceVersion)
+ restoreKeys: |
+ gammapy_data | $(Build.SourceVersion)
+ path: $(GAMMAPY_DATA)
+ displayName: Cache GAMMAPY_DATA
+
- script: |
gammapy download datasets --out=$(GAMMAPY_DATA) --silent --tests
displayName: 'Get GAMMAPY_DATA'
@@ -144,6 +160,14 @@ jobs:
gammapy info
displayName: 'Create gammapy-dev conda environment'
+ - task: Cache@2
+ inputs:
+ key: gammapy_data | $(Build.SourceVersion)
+ restoreKeys: |
+ gammapy_data | $(Build.SourceVersion)
+ path: $(GAMMAPY_DATA)
+ displayName: Cache GAMMAPY_DATA
+
- script: |
source activate gammapy-dev
gammapy download datasets --out=$(GAMMAPY_DATA) --silent --tests
