;ci:windows: cleanup; use preinstalled stack
This commit is contained in:
parent
4612ee22c9
commit
0c27cded98
51
.github/workflows/binaries-windows-arm64.yml
vendored
51
.github/workflows/binaries-windows-arm64.yml
vendored
@ -20,16 +20,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
# things to be cached/restored:
|
# caching
|
||||||
|
|
||||||
- name: process cache of stack global package db
|
|
||||||
id: stack-global-package-db
|
|
||||||
uses: actions/cache@v4
|
|
||||||
with:
|
|
||||||
path: C:\Users\runneradmin\AppData\Roaming\stack\
|
|
||||||
key: ${{ runner.os }}-appdata-roaming-stack-${{ hashFiles('**.yaml') }}
|
|
||||||
restore-keys: |
|
|
||||||
${{ runner.os }}-appdata-roaming-stack
|
|
||||||
|
|
||||||
- name: process cache of stack programs dir # ghc, ghc-included packages and their haddocks, mingw, msys2
|
- name: process cache of stack programs dir # ghc, ghc-included packages and their haddocks, mingw, msys2
|
||||||
id: stack-programs-dir
|
id: stack-programs-dir
|
||||||
@ -42,7 +33,16 @@ jobs:
|
|||||||
restore-keys: |
|
restore-keys: |
|
||||||
${{ runner.os }}-appdata-local-programs-stack
|
${{ runner.os }}-appdata-local-programs-stack
|
||||||
|
|
||||||
- name: process cache of .stack-work
|
- name: process cache of global stack dir
|
||||||
|
id: stack-global-package-db
|
||||||
|
uses: actions/cache@v4
|
||||||
|
with:
|
||||||
|
path: C:\Users\runneradmin\AppData\Roaming\stack\
|
||||||
|
key: ${{ runner.os }}-appdata-roaming-stack-${{ hashFiles('**.yaml') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-appdata-roaming-stack
|
||||||
|
|
||||||
|
- name: process cache of ./.stack-work
|
||||||
uses: actions/cache@v4
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: .stack-work
|
path: .stack-work
|
||||||
@ -101,27 +101,34 @@ jobs:
|
|||||||
# env:
|
# env:
|
||||||
# stack: ${{ matrix.plan.stack }}
|
# stack: ${{ matrix.plan.stack }}
|
||||||
|
|
||||||
- name: Install stack
|
# - name: Install stack
|
||||||
#if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
# #if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
||||||
# this step is needed to get stack.exe into PATH, for now
|
# # this step is needed to get stack.exe into PATH, for now
|
||||||
|
# # NB, no windows ARM binary for stack yet; the x86_64 one works, and builds x86_64 hledger binaries
|
||||||
|
# run: |
|
||||||
|
# curl -sL https://get.haskellstack.org/stable/windows-x86_64.zip -o stack.zip
|
||||||
|
# 7z x stack.zip stack.exe
|
||||||
|
# which stack
|
||||||
|
# printf "stack: "; stack --version
|
||||||
|
# which ./stack
|
||||||
|
# printf "./stack: "; ./stack --version
|
||||||
|
|
||||||
|
# use preinstalled stack
|
||||||
|
- name: Check preinstalled stack version
|
||||||
run: |
|
run: |
|
||||||
curl -sL https://get.haskellstack.org/stable/windows-x86_64.zip -o stack.zip
|
|
||||||
7z x stack.zip stack.exe
|
|
||||||
which stack
|
which stack
|
||||||
printf "stack: "; stack --version
|
printf "stack: "; stack --version
|
||||||
which ./stack
|
|
||||||
printf "./stack: "; ./stack --version
|
|
||||||
|
|
||||||
- name: Install GHC
|
- name: Install GHC
|
||||||
# if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
# if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
||||||
# set PATH=C:\Users\runneradmin\AppData\Local\Programs\stack\local\bin;%PATH%
|
# set PATH=C:\Users\runneradmin\AppData\Local\Programs\stack\local\bin;%PATH%
|
||||||
run: |
|
run: |
|
||||||
./stack --no-terminal setup --install-ghc
|
stack setup --install-ghc
|
||||||
|
|
||||||
- name: Install haskell deps
|
- name: Install haskell deps
|
||||||
run: |
|
run: |
|
||||||
./stack --no-terminal build --test --only-dependencies --dry-run
|
stack build --test --only-dependencies --dry-run
|
||||||
./stack --no-terminal build --test --only-dependencies
|
stack build --test --only-dependencies
|
||||||
|
|
||||||
# XXX ghc-pkg not in path
|
# XXX ghc-pkg not in path
|
||||||
# - name: List dep versions
|
# - name: List dep versions
|
||||||
@ -130,7 +137,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Build all hledger modules warning free, optimised and minimised
|
- name: Build all hledger modules warning free, optimised and minimised
|
||||||
run: |
|
run: |
|
||||||
./stack --no-terminal install --test --force-dirty --ghc-options=-fforce-recomp --ghc-options=-Werror
|
stack install --test --force-dirty --ghc-options=-fforce-recomp --ghc-options=-Werror
|
||||||
# --ghc-options=-split-sections doesn't work on windows, "too many sections"
|
# --ghc-options=-split-sections doesn't work on windows, "too many sections"
|
||||||
# --pedantic
|
# --pedantic
|
||||||
|
|
||||||
|
|||||||
57
.github/workflows/binaries-windows-x64.yml
vendored
57
.github/workflows/binaries-windows-x64.yml
vendored
@ -20,16 +20,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
# things to be cached/restored:
|
# caching
|
||||||
|
|
||||||
- name: process cache of stack global package db
|
|
||||||
id: stack-global-package-db
|
|
||||||
uses: actions/cache@v4
|
|
||||||
with:
|
|
||||||
path: C:\Users\runneradmin\AppData\Roaming\stack\
|
|
||||||
key: ${{ runner.os }}-appdata-roaming-stack-${{ hashFiles('**.yaml') }}
|
|
||||||
restore-keys: |
|
|
||||||
${{ runner.os }}-appdata-roaming-stack
|
|
||||||
|
|
||||||
- name: process cache of stack programs dir # ghc, ghc-included packages and their haddocks, mingw, msys2
|
- name: process cache of stack programs dir # ghc, ghc-included packages and their haddocks, mingw, msys2
|
||||||
id: stack-programs-dir
|
id: stack-programs-dir
|
||||||
@ -42,7 +33,16 @@ jobs:
|
|||||||
restore-keys: |
|
restore-keys: |
|
||||||
${{ runner.os }}-appdata-local-programs-stack
|
${{ runner.os }}-appdata-local-programs-stack
|
||||||
|
|
||||||
- name: process cache of .stack-work
|
- name: process cache of global stack dir
|
||||||
|
id: stack-global-package-db
|
||||||
|
uses: actions/cache@v4
|
||||||
|
with:
|
||||||
|
path: C:\Users\runneradmin\AppData\Roaming\stack\
|
||||||
|
key: ${{ runner.os }}-appdata-roaming-stack-${{ hashFiles('**.yaml') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-appdata-roaming-stack
|
||||||
|
|
||||||
|
- name: process cache of ./.stack-work
|
||||||
uses: actions/cache@v4
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: .stack-work
|
path: .stack-work
|
||||||
@ -101,27 +101,32 @@ jobs:
|
|||||||
# env:
|
# env:
|
||||||
# stack: ${{ matrix.plan.stack }}
|
# stack: ${{ matrix.plan.stack }}
|
||||||
|
|
||||||
- name: Install stack
|
# - name: Install stack
|
||||||
#if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
# #if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
||||||
# this step is needed to get stack.exe into PATH, for now
|
# # this step is needed to get stack.exe into PATH, for now
|
||||||
|
# run: |
|
||||||
|
# curl -sL https://get.haskellstack.org/stable/windows-x86_64.zip -o stack.zip
|
||||||
|
# 7z x stack.zip stack.exe
|
||||||
|
# which stack
|
||||||
|
# printf "stack: "; stack --version
|
||||||
|
# which ./stack
|
||||||
|
# printf "./stack: "; ./stack --version
|
||||||
|
|
||||||
|
- name: Check preinstalled stack version
|
||||||
run: |
|
run: |
|
||||||
curl -sL https://get.haskellstack.org/stable/windows-x86_64.zip -o stack.zip
|
|
||||||
7z x stack.zip stack.exe
|
|
||||||
which stack
|
which stack
|
||||||
printf "stack: "; stack --version
|
printf "stack: "; stack --version
|
||||||
which ./stack
|
|
||||||
printf "./stack: "; ./stack --version
|
|
||||||
|
|
||||||
- name: Install GHC
|
# - name: Install GHC
|
||||||
# if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
# # if: steps.stack-programs-dir.outputs.cache-hit != 'true'
|
||||||
# set PATH=C:\Users\runneradmin\AppData\Local\Programs\stack\local\bin;%PATH%
|
# # set PATH=C:\Users\runneradmin\AppData\Local\Programs\stack\local\bin;%PATH%
|
||||||
run: |
|
# run: |
|
||||||
./stack --no-terminal setup --install-ghc
|
# stack setup --install-ghc
|
||||||
|
|
||||||
- name: Install haskell deps
|
- name: Install haskell deps
|
||||||
run: |
|
run: |
|
||||||
./stack --no-terminal build --test --only-dependencies --dry-run
|
stack build --test --only-dependencies --dry-run
|
||||||
./stack --no-terminal build --test --only-dependencies
|
stack build --test --only-dependencies
|
||||||
|
|
||||||
- name: List dep versions
|
- name: List dep versions
|
||||||
run: |
|
run: |
|
||||||
@ -129,7 +134,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Build all hledger modules warning free, optimised and minimised
|
- name: Build all hledger modules warning free, optimised and minimised
|
||||||
run: |
|
run: |
|
||||||
./stack --no-terminal install --test --force-dirty --ghc-options=-fforce-recomp --ghc-options=-Werror
|
stack install --test --force-dirty --ghc-options=-fforce-recomp --ghc-options=-Werror
|
||||||
# --ghc-options=-split-sections doesn't work on windows, "too many sections"
|
# --ghc-options=-split-sections doesn't work on windows, "too many sections"
|
||||||
# --pedantic
|
# --pedantic
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user