diff --git a/.github/workflows/quick-jobs.yml b/.github/workflows/quick-jobs.yml index 0c77e01d8cf..e8e82a58911 100644 --- a/.github/workflows/quick-jobs.yml +++ b/.github/workflows/quick-jobs.yml @@ -113,16 +113,32 @@ jobs: buildinfo: name: Check Field Syntax Reference runs-on: ubuntu-latest + env: + cabal_build: cabal build buildinfo-reference-generator steps: - - uses: actions/cache@v4 - with: - path: ~/.local/state/cabal - key: linux-store-buildinfo-doc-diff - name: Update Hackage index run: cabal v2-update - uses: actions/checkout@v4 + - name: Generate build plan for correct cache key + run: ${{ env.cabal_build }} --dry-run + - name: Restore cached dependencies + uses: actions/cache/restore@v4 + id: cache + with: + path: ~/.local/state/cabal + key: linux-store-buildinfo-doc-diff-${{ hashfiles('dist-newstyle/cache/plan.json') }} + restore-keys: linux-store-buildinfo-doc-diff + - name: Build buildinfo-reference-generator + run: ${{ env.cabal_build }} - name: Are buildinfo docs up to date? run: make doc/buildinfo-fields-reference.rst + - name: Cache dependencies + uses: actions/cache/save@v4 + if: always() && steps.cache.outputs.cache-hit != 'true' + with: + path: ~/.local/state/cabal + key: ${{ steps.cache.outputs.cache-primary-key }} + release-project: name: Check Release Project runs-on: ubuntu-latest