mirror of
https://github.com/wesnoth/wesnoth
synced 2025-04-18 19:57:04 +00:00
Make whitespace fixing a script.
This commit is contained in:
parent
07a4be462b
commit
73c4e19ea2
4
.github/workflows/ci-scripts/docker.sh
vendored
4
.github/workflows/ci-scripts/docker.sh
vendored
|
@ -41,9 +41,7 @@ execute() {
|
|||
# check for trailing whitespace in hpp|cpp files
|
||||
# check for trailing whitespace in lua files
|
||||
checkindent() {
|
||||
make -C data/tools reindent
|
||||
find src/ -name \*.\[ch\]pp -print0 | xargs -0 sed -i 's/[[:blank:]]*$//'
|
||||
find data/lua/ -name \*.lua -print0 | xargs -0 sed -i 's/[[:blank:]]*$//'
|
||||
./utils/CI/fix_whitespace.sh
|
||||
git status
|
||||
(( $(git status --short | wc -l) == 0 ))
|
||||
}
|
||||
|
|
5
utils/CI/fix_whitespace.sh
Executable file
5
utils/CI/fix_whitespace.sh
Executable file
|
@ -0,0 +1,5 @@
|
|||
#!/bin/bash
|
||||
|
||||
make -C data/tools reindent
|
||||
find src/ -name \*.\[ch\]pp -print0 | xargs -0 sed -i 's/[[:blank:]]*$//'
|
||||
find data/lua/ -name \*.lua -print0 | xargs -0 sed -i 's/[[:blank:]]*$//'
|
Loading…
Reference in New Issue
Block a user