From f2a433e74f8cf577eefbb9c66cf8147cd6525c46 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9mie=20Astor?= Date: Fri, 17 Jan 2020 14:03:29 +0100 Subject: [PATCH] more on caching --- .github/workflows/build.yml | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9911a8aa..f3146482 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -12,13 +12,13 @@ jobs: - uses: actions/setup-haskell@v1 - uses: actions/cache@v1 - id: mdr-cache + id: mdr-bin with: path: mdr key: ${{ runner.os }}-mdr - name: Mdr - if: steps.mdr-cache.outputs.cache-hit != 'true' + if: steps.mdr-bin.outputs.cache-hit != 'true' run: | git clone https://github.com/fennecdjay/mdr cd mdr @@ -28,6 +28,20 @@ jobs: cabal build cabal install + - name: Mdr + if: steps.mdr-bin.outputs.cache-hit == 'true' + run: | + if [ $(git rev-parse HEAD) = $(git ls-remote https://github.com/fennecdjay/mdr.git HEAD | cut -f1) ] + then exit 0 + fi + cd mdr + git pull + cabal update + cabal install --only-dependencies + cabal configure --enable-tests + cabal build + cabal install + - name: Gwion run: | git clone https://github.com/fennecdjay/Gwion -- 2.43.0