From dec5d0bb7e3d1cc90cefc137adf8399ea234810c Mon Sep 17 00:00:00 2001 From: Raffaello Bonghi Date: Tue, 14 Jan 2025 20:08:48 +0000 Subject: [PATCH] Improve CI with auto style code --- .github/workflows/build-and-push.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-and-push.yml b/.github/workflows/build-and-push.yml index 74ae101a..65fde403 100644 --- a/.github/workflows/build-and-push.yml +++ b/.github/workflows/build-and-push.yml @@ -25,7 +25,7 @@ jobs: python -m pip install --upgrade pip pip install flake8 autopep8 - name: Auto style code with autopep8 - run: autopep8 --in-place --aggressive --aggressive --max-line-length 180 . + run: autopep8 --in-place --aggressive --aggressive --recursive . --max-line-length 180 - name: Check for changes run: | if [[ `git status --porcelain` ]]; then @@ -34,10 +34,9 @@ jobs: git config --global user.email "github-actions[bot]@users.noreply.github.com" git add . git commit -m "Auto style code with autopep8" - exit 1 + git push else echo "No changes detected." - fi env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}