;ci: github: windows: tweak caching
This commit is contained in:
parent
1e343a86ae
commit
5b2238696a
20
.github/workflows/windows-nightly.yml
vendored
20
.github/workflows/windows-nightly.yml
vendored
@ -47,16 +47,16 @@ jobs:
|
|||||||
|
|
||||||
# declare/restore cached things
|
# declare/restore cached things
|
||||||
|
|
||||||
- name: Cache stack local bin dir
|
- name: Cache stack global package db
|
||||||
id: stack-local-bin-dir
|
id: stack-global-package-db
|
||||||
uses: actions/cache@v1
|
uses: actions/cache@v1
|
||||||
with:
|
with:
|
||||||
path: C:\Users\runneradmin\AppData\Roaming\stack\
|
path: C:\Users\runneradmin\AppData\Roaming\stack\
|
||||||
key: ${{ runner.os }}-appdata-roaming-stack-${{ hashFiles('**.yaml') }}
|
key: ${{ runner.os }}-appdata-roaming-stack-${{ hashFiles('**.yaml') }}
|
||||||
restore-keys: ${{ runner.os }}-appdata-roaming-stack
|
restore-keys: ${{ runner.os }}-appdata-roaming-stack
|
||||||
|
|
||||||
- name: Cache stack global db # downloaded ghcs, package indexes, third-party haskell deps
|
- name: Cache stack local programs dir
|
||||||
id: stack-global-db
|
id: stack-programs-dir
|
||||||
uses: actions/cache@v1
|
uses: actions/cache@v1
|
||||||
with:
|
with:
|
||||||
path: C:\Users\runneradmin\AppData\Local\Programs\stack\
|
path: C:\Users\runneradmin\AppData\Local\Programs\stack\
|
||||||
@ -113,7 +113,7 @@ jobs:
|
|||||||
# run: echo "::add-path::C:\Users\runneradmin\AppData\Roaming\stack\local\bin"
|
# run: echo "::add-path::C:\Users\runneradmin\AppData\Roaming\stack\local\bin"
|
||||||
|
|
||||||
- name: Install stack
|
- name: Install stack
|
||||||
if: steps.stack-local-bin-dir.outputs.cache-hit != 'true'
|
if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
||||||
# need this step to install stack.exe into PATH for now
|
# need this step to install stack.exe into PATH for now
|
||||||
run: |
|
run: |
|
||||||
curl -skL -o stack.zip http://www.stackage.org/stack/windows-x86_64
|
curl -skL -o stack.zip http://www.stackage.org/stack/windows-x86_64
|
||||||
@ -121,9 +121,9 @@ jobs:
|
|||||||
stack --version
|
stack --version
|
||||||
|
|
||||||
- name: Install GHC
|
- name: Install GHC
|
||||||
if: steps.stack-global-db.outputs.cache-hit != 'true'
|
if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
||||||
run: |
|
run: |
|
||||||
set PATH=C:\Users\runneradmin\AppData\Roaming\stack\local\bin;%PATH%
|
set PATH=C:\Users\runneradmin\AppData\Local\Programs\stack\local\bin;%PATH%
|
||||||
stack --no-terminal setup --install-ghc
|
stack --no-terminal setup --install-ghc
|
||||||
|
|
||||||
# - name: Install shelltestrunner
|
# - name: Install shelltestrunner
|
||||||
@ -131,14 +131,14 @@ jobs:
|
|||||||
# - shelltest --version
|
# - shelltest --version
|
||||||
|
|
||||||
- name: Install haskell deps
|
- name: Install haskell deps
|
||||||
if: steps.stack-global-db.outputs.cache-hit != 'true'
|
if: steps.stack-global-package-db.outputs.cache-hit != 'true'
|
||||||
run: |
|
run: |
|
||||||
set PATH=C:\Users\runneradmin\AppData\Roaming\stack\local\bin;%PATH%
|
set PATH=C:\Users\runneradmin\AppData\Local\Programs\stack\local\bin;%PATH%
|
||||||
stack --no-terminal build --only-dependencies
|
stack --no-terminal build --only-dependencies
|
||||||
|
|
||||||
- name: Build hledger
|
- name: Build hledger
|
||||||
run: |
|
run: |
|
||||||
set PATH=C:\Users\runneradmin\AppData\Roaming\stack\local\bin;%PATH%
|
set PATH=C:\Users\runneradmin\AppData\Local\Programs\stack\local\bin;%PATH%
|
||||||
stack --no-terminal install --ghc-options=-Werror
|
stack --no-terminal install --ghc-options=-Werror
|
||||||
|
|
||||||
# run hledger-lib/hledger functional tests, skipping the ones for addons
|
# run hledger-lib/hledger functional tests, skipping the ones for addons
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user