Skip to content

missed GateSwitch cases #50

missed GateSwitch cases

missed GateSwitch cases #50

Workflow file for this run

# comment to fire up github actions 2
name: "Telomare CI"
on:
pull_request:
push:
jobs:
tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: cachix/install-nix-action@v20
with:
nix_path: nixpkgs=channel:nixos-unstable
extra_nix_config: |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
- uses: cachix/cachix-action@v12
with:
name: telomare
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
extraPullNames: nix-community
- name: Build and test
run: |
echo cachix use
cachix use iohk
echo nix build:
nix build
echo nix run tests:
nix flake check
echo testing telomare-mini-repl:
[[ "8" -eq $(nix develop -c cabal run telomare-mini-repl -- --expr 'succ 7' | tail -n 1) ]]
echo building for legacy nix-shell:
nix-build
nix-shell --run "echo OK"
echo ${{ github.ref }}
echo ${{ github.repository }}
format:
runs-on: ubuntu-latest
steps:
- name: Checkout telomare repository
uses: actions/checkout@v3
- uses: cachix/install-nix-action@v20
with:
extra_nix_config: |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
- uses: cachix/cachix-action@v12
with:
name: telomare
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
extraPullNames: nix-community
- name: stylish-haskell formatting
run: |
nix develop -c stylish-haskell -irv .
output=$(git diff)
if [ "$output" = "" ]; then
echo "Success! No formatting suggestions."
else
echo "Failure: stylish-haskell has some formatting suggestions:"
echo "$output"
exit 1
fi
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout telomare repository
uses: actions/checkout@v3
- uses: cachix/install-nix-action@v20
with:
extra_nix_config: |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
- uses: cachix/cachix-action@v12
with:
name: telomare
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
extraPullNames: nix-community
- name: hlint linting
run: |
output=$(nix develop -c hlint . --no-exit-code)
if [ "$output" = "No hints" ]; then
echo "Success! No Hlint suggestions."
else
echo "Failure: Hlint has some suggestions for your commit"
echo "$output"
exit 1
fi
release:
if: ${{ (github.ref == 'refs/heads/master') && (github.repository == 'Stand-In-Language/stand-in-language') }}
needs: [tests, format]
runs-on: ubuntu-latest
steps:
- name: Checkout telomare repository
uses: actions/checkout@v3
with:
repository: Stand-In-Language/stand-in-language
token: ${{ secrets.API_TOKEN_GITHUB }}
path: ./telomare
- name: Checkout telomare site repository
uses: actions/checkout@v3
with:
repository: Stand-In-Language/stand-in-language.github.io
token: ${{ secrets.API_TOKEN_GITHUB }}
path: ./stand-in-language.github.io
- uses: cachix/install-nix-action@v20
with:
extra_nix_config: |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
- uses: cachix/cachix-action@v12
with:
name: telomare
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
extraPullNames: nix-community
- name: haddock build
run: |
ls
cd telomare
nix develop -c cabal haddock --haddock-hyperlink-source
echo OK Haddock build
- name: haddock copy
run: |
ls
rm -rf stand-in-language.github.io/docs/haddock/
mkdir stand-in-language.github.io/docs/haddock/
cp -r telomare/dist-newstyle/build/x86_64-linux/ghc-9.2.4/telomare-0.1.0.0/doc/html/telomare/. stand-in-language.github.io/docs/haddock
- uses: EndBug/add-and-commit@v7
with:
message: 'haddock documentation automatically updated'
cwd: './stand-in-language.github.io/'
default_author: github_actions