enable magic nix cache to improve build times

This commit is contained in:
Jeffrey C. Ollie
2023-12-22 14:28:27 -06:00
parent a995b6dbb0
commit d8e1aebfcd
3 changed files with 39 additions and 0 deletions

View File

@@ -31,6 +31,12 @@ jobs:
with:
nix_path: nixpkgs=channel:nixos-unstable
# Use cache to minimize build times.
- name: Setup Nix cache
uses: DeterminateSystems/magic-nix-cache-action@main
with:
diagnostic-endpoint: "" # disable telemetry
# Cross-compile the binary. We always use static building for this
# because its the only way to access the headers.
- name: Test Build
@@ -51,6 +57,12 @@ jobs:
with:
nix_path: nixpkgs=channel:nixos-unstable
# Use cache to minimize build times.
- name: Setup Nix cache
uses: DeterminateSystems/magic-nix-cache-action@main
with:
diagnostic-endpoint: "" # disable telemetry
# GhosttyKit is the framework that is built from Zig for our native
# Mac app to access.
- name: Build GhosttyKit
@@ -126,6 +138,12 @@ jobs:
with:
nix_path: nixpkgs=channel:nixos-unstable
# Use cache to minimize build times.
- name: Setup Nix cache
uses: DeterminateSystems/magic-nix-cache-action@main
with:
diagnostic-endpoint: "" # disable telemetry
- name: test
run: nix develop -c zig build -Dapp-runtime=none test
@@ -148,6 +166,11 @@ jobs:
- uses: cachix/install-nix-action@v24
with:
nix_path: nixpkgs=channel:nixos-unstable
# Use cache to minimize build times.
- name: Setup Nix cache
uses: DeterminateSystems/magic-nix-cache-action@main
with:
diagnostic-endpoint: "" # disable telemetry
- name: prettier check
run: nix develop -c prettier --check .
@@ -158,5 +181,10 @@ jobs:
- uses: cachix/install-nix-action@v24
with:
nix_path: nixpkgs=channel:nixos-unstable
# Use cache to minimize build times.
- name: Setup Nix cache
uses: DeterminateSystems/magic-nix-cache-action@main
with:
diagnostic-endpoint: "" # disable telemetry
- name: alejandra check
run: nix develop -c alejandra --check .