Skip to content
This repository has been archived by the owner on Nov 1, 2024. It is now read-only.

Commit

Permalink
ci: move pre-commit out of build-slides (#70)
Browse files Browse the repository at this point in the history
  • Loading branch information
storopoli authored Dec 30, 2023
1 parent d9a7da0 commit 083a171
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 4 deletions.
3 changes: 0 additions & 3 deletions .github/workflows/build-slides.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ jobs:
- name: Cache Nix artifacts
uses: DeterminateSystems/magic-nix-cache-action@v2

- name: Nix pre-commit check
run: nix develop -L . --command bash -c 'pre-commit run --all-files'

- name: Build Slides
run: nix build -L

Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Pre Commit Checks
on:
push:
branches:
- master
- main
pull_request:
branches:
- master
- main

jobs:
build-release:
name: Pre Commit Checks
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v9

- name: Cache Nix artifacts
uses: DeterminateSystems/magic-nix-cache-action@v2

- name: Nix pre-commit check
run: nix develop -L . --command bash -c 'pre-commit run --all-files'
2 changes: 1 addition & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
enable = true;
name = "format julia code";
entry = ''
${pkgs.julia-bin}/bin/julia -e '
${pkgs.julia}/bin/julia -e '
using Pkg
Pkg.activate(".")
Pkg.add("JuliaFormatter")
Expand Down

0 comments on commit 083a171

Please sign in to comment.