Skip to content

Commit

Permalink
Update actions to run on push in case of changes that break on merge
Browse files Browse the repository at this point in the history
  • Loading branch information
jwillikers committed Oct 7, 2024
1 parent df5e342 commit a09d1ba
Show file tree
Hide file tree
Showing 10 changed files with 77 additions and 21 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/check-image-metadata.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,17 @@ name: Check image metadata
- '**.jpeg'
- '**.png'
- '**.webp'
push:
branches: ["main"]
paths:
- .github/workflows/check-image-metadata.yaml
- flake.lock
- check-image-metadata.nu
- '**.gif'
- '**.jpg'
- '**.jpeg'
- '**.png'
- '**.webp'

jobs:
check-image-metadata:
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/clippy-attiny85.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,14 @@ name: Lint Rust code with Clippy
- boards/attiny85/**.rs
- boards/attiny85/.cargo/**
- boards/attiny85/rust-toolchain.toml
push:
branches: ["main"]
paths:
- .github/workflows/clippy-attiny85.yaml
- flake.lock
- boards/attiny85/**.rs
- boards/attiny85/.cargo/**
- boards/attiny85/rust-toolchain.toml

jobs:
clippy-attiny85:
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/flake-checker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ name: Check Nix Flake
paths:
- .github/workflows/flake-checker.yaml
- flake.lock
push:
branches: ["main"]
paths:
- .github/workflows/flake-checker.yaml
- flake.lock

jobs:
flake-checker:
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/format-just.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,14 @@ name: Format justfiles
- '**/.justfile'
- '**/justfile'
- '**/*.just'
push:
branches: ["main"]
paths:
- .github/workflows/format-just.yaml
- flake.lock
- '**/.justfile'
- '**/justfile'
- '**/*.just'

jobs:
format-just:
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/rustfmt.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@ name: Format Rust code
- .github/workflows/rustfmt.yaml
- flake.lock
- '**.rs'
push:
branches: ["main"]
paths:
- .github/workflows/rustfmt.yaml
- flake.lock
- '**.rs'

jobs:
rustfmt:
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/test-check-image-metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Test check-image-metadata.nu
"on":
pull_request:
branches: ["main"]
paths:
- .github/workflows/test-check-image-metadata.yaml
- flake.lock
- check-image-metadata.nu
- check-image-metadata-tests.nu
push:
branches: ["main"]
paths:
- .github/workflows/test-check-image-metadata.yaml
- flake.lock
- check-image-metadata.nu
- check-image-metadata-tests.nu
workflow_dispatch:

jobs:
test-check-image-metadata:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@v14
- uses: DeterminateSystems/magic-nix-cache-action@v8
- name: Run the Nushell tests
run: nix develop --command nu check-image-metadata-tests.nu
18 changes: 0 additions & 18 deletions .github/workflows/test-nushell.yaml

This file was deleted.

8 changes: 8 additions & 0 deletions .github/workflows/yamllint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,14 @@ name: yamllint
- flake.lock
- '**.yaml'
- '**.yml'
push:
branches: ["main"]
paths:
- .github/workflows/yamllint.yaml
- .yamllint.yaml
- flake.lock
- '**.yaml'
- '**.yml'

jobs:
yamllint:
Expand Down
5 changes: 3 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,15 @@ repos:
entry: nix develop --command rustfmt
language: system
types: [file, rust]
- id: test-check-image-metadata-nushell
- id: test-check-image-metadata
entry: nix develop --command nu check-image-metadata-tests.nu
files: |
(?x)^(
check-image-metadata\.nu
check-image-metadata-tests\.nu
)$
language: system
name: test check-image-metadata
name: test check-image-metadata.nu
pass_filenames: false
# - id: rust-clippy-attiny85
# name: Rust clippy ATtiny85
Expand Down
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"mogrify",
"MOSI",
"Noctua",
"nushell",
"Nushell",
"objcopy",
"ostree",
"Perma",
Expand Down

0 comments on commit a09d1ba

Please sign in to comment.