2021-11-20 20:30:40 +01:00
|
|
|
name: "CI"
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
push:
|
|
|
|
jobs:
|
2021-11-20 20:39:24 +01:00
|
|
|
tests-linux:
|
2023-01-29 17:27:20 +01:00
|
|
|
runs-on: ubuntu-latest
|
2021-11-20 20:39:24 +01:00
|
|
|
steps:
|
2023-01-29 17:27:20 +01:00
|
|
|
- uses: actions/checkout@v3
|
|
|
|
- uses: cachix/install-nix-action@v18
|
2021-11-20 20:39:24 +01:00
|
|
|
with:
|
|
|
|
extra_nix_config: "system-features = nixos-test benchmark big-parallel kvm"
|
|
|
|
- run: nix build
|
2023-02-26 23:17:37 +01:00
|
|
|
- run: nix build .#doc
|
2023-01-29 17:27:20 +01:00
|
|
|
- run: nix fmt . -- --check
|
2021-11-20 20:39:24 +01:00
|
|
|
- run: nix flake check
|
|
|
|
tests-darwin:
|
|
|
|
runs-on: macos-11
|
2021-11-20 20:30:40 +01:00
|
|
|
steps:
|
2023-01-29 17:27:20 +01:00
|
|
|
- uses: actions/checkout@v3
|
|
|
|
- uses: cachix/install-nix-action@v18
|
2021-11-20 20:37:06 +01:00
|
|
|
with:
|
|
|
|
extra_nix_config: "system-features = nixos-test benchmark big-parallel kvm"
|
|
|
|
- run: nix build
|
2023-02-26 23:17:37 +01:00
|
|
|
- run: nix build .#doc
|
2023-01-29 17:27:20 +01:00
|
|
|
- run: nix fmt . -- --check
|
2021-11-20 20:31:38 +01:00
|
|
|
- run: nix flake check
|
2023-05-04 01:25:54 +02:00
|
|
|
- name: "Install nix-darwin module"
|
|
|
|
run: |
|
2023-01-29 23:42:58 +01:00
|
|
|
system=$(nix build --no-link --print-out-paths .#checks.x86_64-darwin.integration)
|
|
|
|
${system}/activate-user
|
|
|
|
sudo ${system}/activate
|
2023-05-04 01:25:54 +02:00
|
|
|
- name: "Test nix-darwin module"
|
|
|
|
run: |
|
|
|
|
sudo /run/current-system/sw/bin/agenix-integration
|
|
|
|
- name: "Test home-manager module"
|
|
|
|
run: |
|
|
|
|
# Do the job of `home-manager switch` in-line to avoid rate limiting
|
|
|
|
nix build .#homeConfigurations.integration-darwin.activationPackage
|
|
|
|
./result/activate
|
|
|
|
~/agenix-home-integration/bin/agenix-home-integration
|