-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
.github/workflows: per GHC step, gc after
- Loading branch information
1 parent
9c93336
commit 9d9c86a
Showing
1 changed file
with
26 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,12 +8,35 @@ on: | |
branches: [ master ] | ||
|
||
jobs: | ||
nix-build: | ||
get-ghc-versions: | ||
name: Determine GHC versions to test | ||
runs-on: ubuntu-latest | ||
outputs: | ||
versions: ${{ steps.get-ghc-versions-step.outputs.versions }} | ||
|
||
steps: | ||
- uses: actions/[email protected] | ||
- uses: cachix/install-nix-action@v30 | ||
with: | ||
nix_path: nixpkgs=channel:nixos-unstable | ||
- name: ci.nix | ||
run: nix-build ci.nix | ||
- name: Get GHC Versions from ci.nix | ||
id: get-ghc-versions-step | ||
run: | | ||
echo -n "versions=" >> "$GITHUB_OUTPUT" | ||
nix-instantiate --eval --strict --json -E 'builtins.attrNames (import ./ci.nix { })' >> "$GITHUB_OUTPUT" | ||
nix-build: | ||
runs-on: ubuntu-latest | ||
needs: | ||
- get-ghc-versions | ||
strategy: | ||
matrix: | ||
version: ${{ fromJSON(needs.get-ghc-versions.outputs.versions) }} | ||
- uses: actions/[email protected] | ||
- uses: cachix/install-nix-action@v30 | ||
with: | ||
nix_path: nixpkgs=channel:nixos-unstable | ||
- name: nix-build ci.nix -A ${{ matrix.version }} | ||
run: | | ||
nix-build -A ${{ matrix.version }} | ||
nix-store --gc |