configuration.nix/.forgejo/workflows/check.yml
Jalil David Salamé Messina 46a36b1001
All checks were successful
/ check-renovaterc (push) Successful in 3s
/ check (push) Successful in 8s
/ build-packages (push) Successful in 14s
/ build-vm (push) Successful in 3s
/ report-size (push) Successful in 3s
ci: only run check-renovaterc when the renovaterc changes
Otherwise we are just wasting CI time
2025-05-16 19:11:31 +02:00

50 lines
1.9 KiB
YAML

on:
push:
jobs:
check:
runs-on: nixos
steps:
- uses: "https://git.salame.cl/actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683" # v4
- run: nix --version
- name: Run checks
run: |
nix-fast-build --max-jobs 2 --no-nom --skip-cached --no-link \
--flake ".#checks.$(nix eval --raw --impure --expr builtins.currentSystem)"
build-packages:
runs-on: nixos
needs: check
steps:
- uses: "https://git.salame.cl/actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683" # v4
- run: nix --version
- name: Build target
run: |
nix-fast-build --max-jobs 1 --no-nom --skip-cached --no-link \
--flake ".#packages.$(nix eval --raw --impure --expr builtins.currentSystem)"
build-vm:
runs-on: nixos
needs: build-packages
steps:
- uses: "https://git.salame.cl/actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683" # v4
- run: nix --version
- name: Build VM configuration
run: |
nix build --print-build-logs '.#nixosConfigurations.vm.config.system.build.toplevel'
report-size:
runs-on: nixos
needs:
- build-packages
- build-vm
steps:
- uses: "https://git.salame.cl/actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683" # v4
- run: nix --version
- name: Create Size Report
uses: "https://git.salame.cl/jalil/nix-flake-outputs-size@b7e76df81383680ae01fada8db4d2c6f99391d8b" # main
with:
# Create a comment on the associated PR
comment-on-pr: ${{ github.ref_name != 'main' }}
# Generate artifacts on main (to speed up comparisons)
generate-artifact: ${{ github.ref_name == 'main' }}
# Generate comparisons to main
do-comparison: 'true'
# This job's name (so we can find the artifacts)
job-name: report-size