Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -180,8 +180,15 @@ jobs:

if normalize_line_endings(committed) != normalize_line_endings(working):
raise SystemExit("gradlew.bat changed beyond CRLF/LF normalization")
if path.stat().st_mode & (stat.S_IXUSR | stat.S_IXGRP | stat.S_IXOTH):
raise SystemExit("gradlew.bat unexpectedly became executable")
git_mode = subprocess.check_output(
["git", "ls-files", "--stage", "--", "gradlew.bat"],
text=True,
).split(maxsplit=1)[0]
if git_mode not in {"100644", "100755"}:
raise SystemExit("gradlew.bat has an unexpected Git mode")
actual_executable = bool(path.stat().st_mode & (stat.S_IXUSR | stat.S_IXGRP | stat.S_IXOTH))
if actual_executable != (git_mode == "100755"):
raise SystemExit("gradlew.bat executable mode differs from the Git index")
PY
echo 'Accepted CRLF/LF-only normalization of gradlew.bat.'
dirty=
Expand Down