Add syntax sugar for nested sigma-types #466
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: GHCJS (build and deploy Rzk playground) | |
on: | |
push: | |
branches: [main, develop] | |
tags: [v*] | |
paths: | |
- .github/workflows/ghcjs.yml | |
- rzk/** | |
- rzk-js/** | |
- rzk-playground/** | |
- stack.yaml | |
- "**/*.nix" | |
pull_request: | |
branches: [develop] | |
paths: | |
- .github/workflows/ghcjs.yml | |
- rzk/** | |
- rzk-js/** | |
- rzk-playground/** | |
- stack.yaml | |
- "**/*.nix" | |
workflow_dispatch: # allow triggering this workflow manually | |
permissions: | |
contents: write | |
jobs: | |
build-and-deploy-with-ghcjs: | |
name: "Build with GHCJS (and deploy Rzk playground)" | |
runs-on: ubuntu-latest | |
steps: | |
- name: 📥 Checkout repository | |
uses: actions/checkout@v4 | |
- name: ❄️ Install Nix | |
uses: nixbuild/nix-quick-install-action@v25 | |
with: | |
nix_conf: | | |
substituters = https://cache.nixos.org/ https://cache.iog.io https://nix-community.cachix.org https://miso-haskell.cachix.org | |
trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs= hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ= miso-haskell.cachix.org-1:6N2DooyFlZOHUfJtAx1Q09H0P5XXYzoxxQYiwn6W1e8= | |
keep-outputs = true | |
- name: 👝 Restore and Cache Nix store | |
uses: nix-community/cache-nix-action@v5 | |
with: | |
primary-key: ${{ runner.os }}-nix-${{ hashfiles('./flake.nix', './flake.lock', '.github/workflows/ghcjs.yml', './rzk/rzk.cabal') }} | |
restore-prefixes-first-match: | | |
${{ runner.os }}-nix-${{ hashfiles('./flake.nix', './flake.lock', '.github/workflows/ghcjs.yml', './rzk/rzk.cabal') }} | |
${{ runner.os }}-nix- | |
gc-max-store-size: 7000000000 | |
purge: true | |
purge-prefixes: ${{ runner.os }}-nix- | |
purge-created: 0 | |
purge-primary-key: never | |
- name: 👝 Restore and cache NodeJS deps | |
uses: actions/cache@v4 | |
with: | |
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-node- | |
path: | | |
~/.npm | |
- name: 🔨 Remove lexer and parser generator files | |
run: | | |
rm -f rzk/src/Language/Rzk/Syntax/Lex.x | |
rm -f rzk/src/Language/Rzk/Syntax/Par.y | |
# Uncomment to debug this job | |
# - name: Setup tmate session | |
# uses: mxschmitt/action-tmate@v3 | |
- name: 🔨 Build Playground | |
env: | |
ASSET_URL: /${{ github.event.repository.name }}/${{ github.ref_name }}/playground | |
run: nix run .#release-rzk-playground | |
- name: 🔨 Save flake from garbage collection | |
run: nix run .#save-flake | |
- name: '🚀 Publish JS "binaries" (${{ github.ref_name }})' | |
if: ${{ github.ref_name != 'main' && github.event_name == 'push' }} | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
folder: rzk-playground-release | |
target-folder: ${{ github.ref_name }}/playground | |
clean: false | |
single-commit: true | |
- name: '🚀 Publish JS "binaries" (latest)' | |
if: ${{ startsWith(github.ref, 'refs/tags/') && startsWith(github.ref_name, 'v') && github.event_name == 'push' }} | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
folder: rzk-playground-release | |
target-folder: latest/playground | |
clean: false | |
single-commit: true | |
- name: '🚀 Publish JS "binaries"' | |
if: ${{ github.ref_name == 'main' && github.event_name == 'push' }} | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
folder: rzk-playground-release | |
target-folder: playground | |
clean: false | |
single-commit: true |