name: "Cachix" on: push: paths: - '**.nix' - '**.age' - 'pkgs/**' - 'flake.nix' - 'flake.lock' - '.github/workflows/cachix.yaml' jobs: format-check: name: Format check runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 - uses: cachix/install-nix-action@v16 - name: Run alejandra run: nix run nixpkgs#alejandra -- --check . flake-check: name: Flake check runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 - uses: cachix/install-nix-action@v16 - uses: cachix/cachix-action@v10 with: name: alarsyo authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' extraPullNames: "nix-community" - name: Build package run: nix flake check build-pkgs: name: Nix packages runs-on: ubuntu-latest needs: [ flake-check, format-check ] strategy: fail-fast: false matrix: name: - grafanaDashboards/nginx - grafanaDashboards/node-exporter - kaleidoscope-udev-rules - sddm-sugar-candy - spot steps: - uses: actions/checkout@v2 - uses: cachix/install-nix-action@v16 - uses: cachix/cachix-action@v10 with: name: alarsyo authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' extraPullNames: "nix-community" - name: Build package run: nix build -L .#"${{ matrix.name }}" build-configs: name: NixOS configs runs-on: ubuntu-latest needs: [ build-pkgs ] strategy: fail-fast: false matrix: name: - boreal - hades - poseidon - zephyrus steps: - uses: actions/checkout@v2 - uses: cachix/install-nix-action@v16 - uses: cachix/cachix-action@v10 with: name: alarsyo authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' extraPullNames: "nix-community" - name: Build package run: nix build -L .#nixosConfigurations."${{ matrix.name }}".config.system.build.toplevel