diff --git a/.github/workflows/build-site.yml b/.github/workflows/build-site.yml new file mode 100644 index 0000000..130d8ed --- /dev/null +++ b/.github/workflows/build-site.yml @@ -0,0 +1,29 @@ +name: build-site + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + + workflow_dispatch: + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - uses: cachix/install-nix-action@v20 + with: + nix_path: nixpkgs=channel:nixos-unstable + - name: Build Sprokkel + run: nix build .#sprokkel + + - name: Build site + run: ./result/bin/sprokkel build + + - name: Upload artifact + uses: actions/upload-pages-artifact@v3 + with: + path: ./out