diff --git a/.github/workflows/onpush_builder.yaml b/.github/workflows/onpush_builder.yaml index fa2dac660..ad1b4a4fc 100644 --- a/.github/workflows/onpush_builder.yaml +++ b/.github/workflows/onpush_builder.yaml @@ -14,27 +14,6 @@ on: - "**/config.*" jobs: - make-executable: - runs-on: ubuntu-latest - steps: - - name: Checkout Repo - uses: actions/checkout@v3 - - - name: Make scripts executable - run: | - echo "Starting" - git config core.filemode true - # shellcheck disable=SC2086,SC2046 - #git update-index --chmod=+x $(find . -type f -iname "*.sh") - chmod u+x $(find . -type f -iname "*.sh") - #git commit -am "fixing the script permissions..." - - name: Commit if needed - uses: EndBug/add-and-commit@v9 - with: - commit: -u - message: "GitHub bot : scripts executable" - default_author: github_actions - check-addon-changes: runs-on: ubuntu-latest needs: make-executable @@ -50,6 +29,30 @@ jobs: with: filters: .github/paths-filter.yml + make-executable: + if: ${{ needs.check-addon-changes.outputs.changedAddons != '[]' }} + needs: check-addon-changes + runs-on: ubuntu-latest + steps: + - name: Checkout Repo + uses: actions/checkout@v3 + - name: Make scripts executable + run: | + echo "Starting" + git config core.filemode true + # shellcheck disable=SC2086,SC2046 + #git update-index --chmod=+x $(find "$path" -type f -iname "*.sh") + chmod u+x $(find "$path" -type f -iname "*.sh") + #git commit -am "fixing the script permissions..." + with: + path: "./${{ matrix.addon }}" + - name: Commit if needed + uses: EndBug/add-and-commit@v9 + with: + commit: -u + message: "GitHub bot : scripts executable" + default_author: github_actions + lint_config: if: ${{ needs.check-addon-changes.outputs.changedAddons != '[]' }} needs: check-addon-changes