Skip to content

Commit c5733f8

Browse files
authored
Fix git unmodified check in CI (#409)
the diff-index picks up changes if files have been touched
1 parent 5711856 commit c5733f8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

.github/workflows/generate-docs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
4747
- name: Check for modified files
4848
id: git-check
49-
run: echo ::set-output name=modified::$(if git diff-index --ignore-submodules --quiet HEAD --; then echo "false"; else echo "true"; fi)
49+
run: echo "modified=$(if [[ -z $(git status --porcelain --untracked-files=no --ignore-submodules) ]]; then echo "false"; else echo "true"; fi)" >> "$GITHUB_OUTPUT"
5050

5151
- name: Commit changes, if any
5252
if: steps.git-check.outputs.modified == 'true'

0 commit comments

Comments
 (0)