-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (45 loc) · 1.26 KB
/
build.yml
File metadata and controls
45 lines (45 loc) · 1.26 KB
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
37
38
39
40
41
42
43
44
45
name: Build
on:
push:
branches: [main]
jobs:
build:
strategy:
matrix:
build:
- os: ubuntu-latest
system: x86_64-linux
- os: macos-latest
system: aarch64-darwin
runs-on: ${{ matrix.build.os }}
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v25
- uses: cachix/cachix-action@v14
with:
name: create-pin-refs
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- run: |
packages=(
default
create-pin-refs
test
)
for pkg in "${packages[@]}";do
nix build .#"$pkg"
cachix push create-pin-refs ./result
cachix pin create-pin-refs "$pkg".${{ matrix.build.system }} ./result --keep-revisions 1
done
build-only-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v25
- uses: cachix/cachix-action@v14
with:
name: create-pin-refs
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- run: |
nix build .#test-linux
cachix push create-pin-refs ./result
cachix pin create-pin-refs test-linux ./result --keep-revisions 1