diff --git a/.github/actions/gradle-command-on-pr/action.yaml b/.github/actions/gradle-command-on-pr/action.yaml index 546e9eada..08bcc04a2 100644 --- a/.github/actions/gradle-command-on-pr/action.yaml +++ b/.github/actions/gradle-command-on-pr/action.yaml @@ -38,7 +38,9 @@ runs: - name: Check for modified files shell: bash id: git-check - run: echo modified=$(if git diff-index --quiet HEAD --; then echo "false"; else echo "true"; fi) >> $GITHUB_OUTPUT + run: | + git update-index --refresh + echo modified=$(if git diff-index --quiet HEAD --; then echo "false"; else echo "true"; fi) >> $GITHUB_OUTPUT - name: Commit to the PR branch shell: bash