File tree Expand file tree Collapse file tree 1 file changed +20
-4
lines changed Expand file tree Collapse file tree 1 file changed +20
-4
lines changed Original file line number Diff line number Diff line change @@ -113,16 +113,32 @@ jobs:
113
113
buildinfo :
114
114
name : Check Field Syntax Reference
115
115
runs-on : ubuntu-latest
116
+ env :
117
+ cabal_build : cabal build buildinfo-reference-generator
116
118
steps :
117
- - uses : actions/cache@v4
118
- with :
119
- path : ~/.local/state/cabal
120
- key : linux-store-buildinfo-doc-diff
121
119
- name : Update Hackage index
122
120
run : cabal v2-update
123
121
- uses : actions/checkout@v4
122
+ - name : Generate build plan for correct cache key
123
+ run : ${{ env.cabal_build }} --dry-run
124
+ - name : Restore cached dependencies
125
+ uses : actions/cache/restore@v4
126
+ id : cache
127
+ with :
128
+ path : ~/.local/state/cabal
129
+ key : linux-store-buildinfo-doc-diff-${{ hashfiles('dist-newstyle/cache/plan.json') }}
130
+ restore-keys : linux-store-buildinfo-doc-diff
131
+ - name : Build buildinfo-reference-generator
132
+ run : ${{ env.cabal_build }}
124
133
- name : Are buildinfo docs up to date?
125
134
run : make doc/buildinfo-fields-reference.rst
135
+ - name : Cache dependencies
136
+ uses : actions/cache/save@v4
137
+ if : always() && steps.cache.outputs.cache-hit != 'true'
138
+ with :
139
+ path : ~/.local/state/cabal
140
+ key : ${{ steps.cache.outputs.cache-primary-key }}
141
+
126
142
release-project :
127
143
name : Check Release Project
128
144
runs-on : ubuntu-latest
You can’t perform that action at this time.
0 commit comments