Skip to content

Commit

Permalink
Fixed prepare-commit-msg for ruff git hook (#490)
Browse files Browse the repository at this point in the history
  • Loading branch information
brownbaerchen authored Sep 24, 2024
1 parent 3ac9d55 commit a16dc4b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/contrib/02_continuous_integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ export files=$(git diff --staged --name-only HEAD | grep .py | sed -e "s,^,$(git
if [[ $files != "" ]]
then
export ruff_output=$(ruff check --quiet $files)
if [[ "$ruff_output" != 0 ]]
if [[ "$ruff_output" != "" ]]
then
git interpret-trailers --in-place --trailer "$(echo "$ruff_output" | sed -e 's/^/#/')" "$COMMIT_MSG_FILE"
git interpret-trailers --in-place --trailer "#!!!!!!!!!! WARNING: RUFF FAILED !!!!!!!!!!" "$COMMIT_MSG_FILE"
Expand Down

0 comments on commit a16dc4b

Please sign in to comment.