From 8bc9a4e87bb96433fd626cb5b0d515bf6b87eeae Mon Sep 17 00:00:00 2001 From: Antoine Martin Date: Tue, 11 Jan 2022 11:56:30 +0100 Subject: [PATCH] ci: build packages in parallel --- .github/workflows/build-flake-packages.sh | 10 ---------- .github/workflows/cachix.yaml | 17 ++++++++++++++++- 2 files changed, 16 insertions(+), 11 deletions(-) delete mode 100755 .github/workflows/build-flake-packages.sh diff --git a/.github/workflows/build-flake-packages.sh b/.github/workflows/build-flake-packages.sh deleted file mode 100755 index 4d002c7..0000000 --- a/.github/workflows/build-flake-packages.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/sh - -set -xe - -PACKAGES=$(nix flake show --json \ - | jq '.packages."x86_64-linux" | keys[]') - -for package in $PACKAGES; do - nix build --verbose -L .#$package -done diff --git a/.github/workflows/cachix.yaml b/.github/workflows/cachix.yaml index f6b830f..accee21 100644 --- a/.github/workflows/cachix.yaml +++ b/.github/workflows/cachix.yaml @@ -9,11 +9,26 @@ on: jobs: build: runs-on: ubuntu-latest + + strategy: + matrix: + name: + - emacsPgtkGcc + - 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 }}' - - run: .github/workflows/build-flake-packages.sh + + - name: Build package + run: nix build --verbose -L .#"${{ matrix.name }}"