diff --git a/.github/workflows/home.yml b/.github/workflows/home.yml new file mode 100644 index 00000000..25225092 --- /dev/null +++ b/.github/workflows/home.yml @@ -0,0 +1,59 @@ +name: Home + +on: + pull_request: + push: + branches: + - master + paths-ignore: + - 'GNOME.md' + - 'README.md' + - 'notes/**' + - '.git-crypt/**' + - '.gitattributes' + - '.gitignore' + - 'system/**' + - 'outputs/os.nix' + - 'switch' + - '.mergify.yml' + - 'garnix.yaml' + +jobs: + build: + runs-on: ubuntu-latest + + strategy: + fail-fast: true + matrix: + config_name: + - hyprland-edp + - hyprland-hdmi + - hyprland-hdmi-mutable + - xmonad-edp + - xmonad-hdmi + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Push images to ECR + uses: ./.github/actions/push-image-to-ecr + with: + name: ${{ matrix.image_name }} + + steps: + - uses: actions/checkout@v2.3.2 + + - name: "Install Nix ❄️" + uses: cachix/install-nix-action@v30 + + - name: "Install Cachix ❄️" + uses: cachix/cachix-action@v15 + with: + name: gvolpe-nixos + authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}" + + # Needed because cachix is also installed by Home Manager + - name: "Set priority flag for Cachix 🚩" + run: nix-env --set-flag priority 0 cachix + + - name: "Build ${{ matrix.config_name }} Home Manager config 🏠" + run: nix build .#homeConfigurations.${{ matrix.config_name }}.activationPackage -L diff --git a/.github/workflows/nixos.yml b/.github/workflows/nixos.yml new file mode 100644 index 00000000..d412c4f6 --- /dev/null +++ b/.github/workflows/nixos.yml @@ -0,0 +1,61 @@ +name: NixOS + +on: + pull_request: + paths-ignore: + - 'home/**' + push: + branches: + - master + paths-ignore: + - 'GNOME.md' + - 'README.md' + - 'notes/**' + - '.git-crypt/**' + - '.gitattributes' + - '.gitignore' + - 'home/**' + - 'outputs/hm.nix' + - 'switch' + - '.mergify.yml' + - 'garnix.yaml' + +jobs: + build: + runs-on: ubuntu-latest + + strategy: + fail-fast: true + matrix: + hostname: + - dell-xps + - thinkpad-x1 + - tongfang-amd + - xmod + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Push images to ECR + uses: ./.github/actions/push-image-to-ecr + with: + name: ${{ matrix.image_name }} + + steps: + - uses: actions/checkout@v2.3.2 + + - name: "Install Nix ❄️" + uses: cachix/install-nix-action@v30 + + - name: "Install Cachix ❄️" + uses: cachix/cachix-action@v15 + with: + name: gvolpe-nixos + authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}" + + # Needed because cachix is also installed by Home Manager + - name: "Set priority flag for Cachix 🚩" + run: nix-env --set-flag priority 0 cachix + + - name: "Build ${{ matrix.config_name }} Home Manager config 🏠" + run: nix build .#homeConfigurations.${{ matrix.config_name }}.activationPackage -L + diff --git a/.github/workflows/update-metals.yml b/.github/workflows/update-metals.yml index 0530d0da..3d021650 100644 --- a/.github/workflows/update-metals.yml +++ b/.github/workflows/update-metals.yml @@ -8,7 +8,7 @@ jobs: fetcher: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2.3.2 - name: "Install Nix ❄️" uses: cachix/install-nix-action@v18