Skip to content

Commit 27c2eb1

Browse files
fix(actions): formatting check
Signed-off-by: Anhad Singh <[email protected]>
1 parent 85c7cbd commit 27c2eb1

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

.github/workflows/build.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,12 @@ jobs:
2525
run: |
2626
sudo apt-get update
2727
sudo apt-get install -y nasm make
28-
python3 -m pip install requests xbstrap
2928
- name: Build Documentation
3029
run: make doc
3130
- name: Formatting Check
3231
run: |
33-
./aero.py --fmt
34-
git diff-index --quiet HEAD -- || (printf "${RED}error${NOCOLOR}: formatting check failed, run \`./aero.py --fmt\`\n" && exit 1)
32+
make check_fmt
33+
git diff-index --quiet HEAD -- || (printf "${RED}error${NOCOLOR}: formatting check failed, run \`make fmt\`\n" && exit 1)
3534
- name: Deploy documentation
3635
uses: peaceiris/actions-gh-pages@v3
3736
if: github.ref == 'refs/heads/master' && (github.event_name == 'push' || github.event_name == 'schedule')

Makefile

+6
Original file line numberDiff line numberDiff line change
@@ -86,3 +86,9 @@ doc:
8686
ifeq ($(open),yes)
8787
xdg-open target/doc/index.html
8888
endif
89+
90+
fmt:
91+
cd $(SOURCE_DIR) && cargo fmt
92+
93+
check_fmt:
94+
cd $(SOURCE_DIR) && cargo fmt -- --check

0 commit comments

Comments
 (0)