-
-
Notifications
You must be signed in to change notification settings - Fork 45
39 lines (29 loc) · 887 Bytes
/
ci-check-fmt.yaml
File metadata and controls
39 lines (29 loc) · 887 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Check Fmt
on:
workflow_call:
secrets:
build_buddy_token:
required: true
defaults:
run:
shell: bash
jobs:
check_fmt:
runs-on: ubicloud-standard-8-ubuntu-2404
steps:
- uses: actions/checkout@v5
- uses: ./.github/actions/setup-bazel
with:
build_buddy_token: ${{ secrets.build_buddy_token }}
- name: Format bazel
run: bazel run //tools/buildifier -- $(git ls-files "*.bzl" "*.bazel" | xargs ls 2>/dev/null)
- name: Format dprint
run: bazel run //tools/dprint -- fmt
- name: Format buf
run: bazel run //tools/buf -- format -w --disable-symlinks --debug
- name: Format just
run: bazel run //tools/just -- --unstable --fmt
- name: Format shfmt
run: bazel run //tools/shfmt -- -w .
- name: Exit on diff
run: git diff --exit-code