-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (36 loc) · 1.03 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: "Build PDF"
on:
pull_request:
push:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: cachix/install-nix-action@v22
with:
github_access_token: ${{ secrets.GITHUB_TOKEN }}
extra_nix_config: |
store = /home/runner/nix
auto-optimise-store = true
keep-outputs = true
keep-derivations = true
- name: Cache Nix
uses: actions/[email protected]
with:
key: ${{ hashfiles('flake.nix') }}
path: ~/nix
# See https://github.com/actions/cache/issues/749#issuecomment-1551707934
- run: nix build '.#nactl'
- run: cp /home/runner/nix$(realpath result) nactl.pdf
- run: nix build '.#kactl'
- run: cp /home/runner/nix$(realpath result) kactl.pdf
- run: nix build '.#nactl-complete'
- run: cp /home/runner/nix$(realpath result) nactl-complete.pdf
- uses: actions/upload-artifact@v3
with:
name: PDFs
path: |
nactl.pdf
kactl.pdf
nactl-complete.pdf