This commit is contained in:
Gerg-L 2023-07-10 05:46:15 -04:00
parent 91967fa6ef
commit 2b7aa0177c
2 changed files with 37 additions and 1 deletions

View file

@ -4,7 +4,7 @@
"workflow_dispatch": null,
"schedule": [
{
"cron": "0 0 * * *"
"cron": "0 10 * * *"
}
]
},

View file

@ -0,0 +1,36 @@
name: Nix Flake actions
on:
pull_request:
push:
branches:
- master
- main
jobs:
nix-matrix:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- uses: actions/checkout@v3
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v4
- id: set-matrix
name: Generate Nix Matrix
run: |
set -Eeu
echo "matrix=$(nix eval --json '.#githubActions.matrix')" >> "$GITHUB_OUTPUT"
nix-build:
needs: nix-matrix
runs-on: ${{ matrix.os }}
strategy:
matrix: ${{fromJSON(needs.nix-matrix.outputs.matrix)}}
steps:
- uses: actions/checkout@v3
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v4
- name: Run Nix cache
uses: DeterminateSystems/magic-nix-cache-action@v1
- run: nix build -L ".#${{ matrix.attr }}"