-
Notifications
You must be signed in to change notification settings - Fork 6
36 lines (35 loc) · 1.07 KB
/
nix.yaml
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: nix-build
on:
pull_request:
push:
branches:
- main
jobs:
build-nix-packages:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v25
with:
nix_path: nixpkgs=channel:nixos-unstable
# Later, we can use Cachix or similar to distribute the binaries automatically.
- uses: DeterminateSystems/magic-nix-cache-action@v2
# This saves us against build failures because the clojure deps
# are not yet locked. Since the CI does not automatically release
# nix artifacts yet, this reduction in friction is harmless for now
# and only means a releaser should run deps-lock and commit.
# This can be addressed inclusively with automation around releases.
- run: |
nix develop '.#depsLock' \
--command bash -c \
"nix run github:jlesquembre/clj-nix#deps-lock"
- run: |
nix build \
-L \
--no-link \
'.#bin'
- run: |
nix build \
-L \
-o ./imgTarball \
'.#ociImg'