Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 10 additions & 43 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
name: CI

# Run CI when a PR is opened against the branch `master`
# and when one pushes a commit to `master`.
on:
push:
branches: [master]
pull_request:
branches: [master]

# Run CI on all 3 latest OSes
jobs:
build:
strategy:
Expand All @@ -17,53 +14,23 @@ jobs:
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v6

- uses: purescript-contrib/setup-purescript@main
- uses: actions/setup-node@v6
with:
purescript: "0.15.9"
purs-tidy: "0.9.2"
psa: "0.8.2"
spago: "0.20.9"
node-version: "24"
cache: npm

- name: Cache PureScript dependencies
uses: actions/cache@v2
with:
key: ${{ runner.os }}-spago-${{ hashFiles('**/*.dhall') }}
path: |
.spago
output

- name: Set up Node toolchain
uses: actions/setup-node@v2
with:
node-version: "16"
- run: npm ci

- name: Cache NPM dependencies
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-

# Compile the library/project
# censor-lib: ignore warnings emitted by dependencies
# strict: convert warnings into errors
# Note: `purs-args` actually forwards these args to `psa`
- name: Build the project
run: |
spago build --purs-args "--censor-lib --strict"
run: npm run build

- name: Run tests
run: |
spago test
run: npm test

- name: Check Formatting
- name: Check lint and formatting
if: runner.os == 'Linux'
run: |
purs-tidy check src test
npm run lint
npm run format:check
3 changes: 3 additions & 0 deletions .oxfmtrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"trailingComma": "es5"
}
Loading
Loading