From 542f8a61bc2d6f795524b6794ebeaa38ed137b9d Mon Sep 17 00:00:00 2001 From: Kristian Krsnik Date: Fri, 18 Aug 2023 19:29:37 +0200 Subject: [PATCH] added install-nix --- .github/workflows/hugo.yaml | 26 +++++++++++--------------- 1 file changed, 11 insertions(+), 15 deletions(-) diff --git a/.github/workflows/hugo.yaml b/.github/workflows/hugo.yaml index d8738e5..3d91989 100644 --- a/.github/workflows/hugo.yaml +++ b/.github/workflows/hugo.yaml @@ -32,25 +32,21 @@ jobs: runs-on: ubuntu-latest container: nixos/nix steps: - - name: Add nix channel - run: "nix-channel --add https://nixos.org/channels/nixpkgs-unstable" - - name: Update nix channel - run: "nix-channel --update" - - name: Install Node dependency for GitHub actions - env: - NIXPKGS_ALLOW_INSECURE: "1" - run: "nix-env -iA nixpkgs.nodejs_16" - - name: Checkout - uses: actions/checkout@v3 + - uses: actions/checkout@v3 + - uses: cachix/install-nix-action@v22 with: - submodules: recursive + github_access_token: ${{ secrets.GITHUB_TOKEN }} + + - name: Build with Nix + run: "nix build" + + - name: Copy public folder + run: "cp -r result/. public/" + - name: Setup Pages id: pages uses: actions/configure-pages@v3 - - name: Build with Nix - run: "nix build --experimental-features 'nix-command flakes'" - - name: Copy public folder - run: "cp -r result/. public/" + - name: Upload artifact uses: actions/upload-pages-artifact@v2 with: