ci: extend lint run to run 'make indent'

Acked-by: Mike Rapoport <rppt@linux.ibm.com>
Signed-off-by: Adrian Reber <areber@redhat.com>
This commit is contained in:
Adrian Reber 2021-07-19 10:01:19 +00:00 committed by Andrei Vagin
parent 70833bcf29
commit e2a45d7867

View file

@ -5,9 +5,21 @@ on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
container:
image: registry.fedoraproject.org/fedora:latest
steps:
- uses: actions/checkout@v2
- name: Install tools
run: sudo apt-get install -qqy flake8 shellcheck
run: sudo dnf -y install git make python3-flake8 ShellCheck clang-tools-extra which findutils
- uses: actions/checkout@v2
- name: Run make lint
run: make lint
- name: Run make indent
run: >
make indent &&
STATUS=$(git status --porcelain) &&
if [ ! -z "$STATUS" ]; then
echo "FAIL: some files are not correctly formatted.";
echo "$STATUS"
echo "FAIL: please run 'make indent'";
exit 1;
fi