shell variable nonsense #4
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build the website | |
on: | |
# Runs on pushes targeting the default branch | |
push: | |
branches: | |
- '*' | |
- '!main' | |
pull_request: | |
branches: | |
- '*' | |
- '!main' | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
# when there are subsequent pushes on the same branch, cancel existing jobs and run the new job instead. | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
# Single deploy job since we're just building | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
submodules: 'recursive' | |
- name: Install Nix | |
uses: cachix/install-nix-action@v17 | |
- name: Build website | |
run: nix build | |
- name: Download IPFS | |
run: ./.github/github_install_ipfs.sh | |
- name: Print IPFS hahes | |
run: export PATH="/tmp/kubo:$PATH"; ./result/www/ipfs-add.sh --pin=false; cat result/ipfs.url | |
- name: Compare IPFS hashes | |
run: export PATH="/tmp/kubo:$PATH"; test "ipfs://$(./result/www/ipfs-add.sh --pin=false)" = "$(cat result/ipfs.url)" |