Restrict numpy<2
and bump actions (#38)
#109
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: format-check | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- 'main' | |
- 'master' | |
- /^release-.*$/ | |
tags: '*' | |
pull_request: | |
jobs: | |
format-check: | |
name: Format check | |
runs-on: ubuntu-latest | |
steps: | |
- uses: julia-actions/setup-julia@latest | |
with: | |
version: 1.6.0 | |
- uses: actions/checkout@v4 | |
- name: Instantiate `format` environment and format | |
run: | | |
julia --project=format -e 'using Pkg; Pkg.instantiate()' | |
julia --project=format 'format/run.jl' | |
- name: Format check | |
run: | | |
julia -e ' | |
out = read(`git diff --name-only`, String) | |
if out == "" | |
exit(0) | |
else | |
@error "Some files have not been formatted!" | |
write(stdout, out) | |
exit(1) | |
end' |