Skip to content

Commit e973f79

Browse files
Add format checks
1 parent 0e8ea80 commit e973f79

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

.github/workflows/check.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,31 @@ jobs:
3333
- id: set_image
3434
run: echo "CI_IMAGE=${{ env.CI_IMAGE }}" >> $GITHUB_OUTPUT
3535

36+
check-fmt:
37+
runs-on: ubuntu-latest
38+
timeout-minutes: 20
39+
needs: [set-image]
40+
container:
41+
image: ${{ needs.preflight.outputs.IMAGE }}
42+
steps:
43+
- uses: actions/checkout@v4
44+
- name: Cargo fmt
45+
id: required
46+
run: cargo +nightly fmt --all -- --check
47+
48+
check-toml-format:
49+
runs-on: ubuntu-latest
50+
timeout-minutes: 20
51+
needs: [check-fmt]
52+
container:
53+
image: ${{ needs.preflight.outputs.IMAGE }}
54+
steps:
55+
- uses: actions/checkout@v4
56+
- name: check toml format
57+
run: |
58+
taplo format --check --config .config/taplo.toml
59+
echo "Please run `taplo format --config .config/taplo.toml` to fix any toml formatting issues"
60+
3661
check:
3762
name: Cargo check
3863
# TODO: replace `parity-default` with `ubuntu-latest` when the repo becomes public.

0 commit comments

Comments
 (0)