mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-22 09:19:03 +00:00
Meta: Ignore everything after the git cut line in a lint-commit.sh hook
I have set up a commit.verbose variable in my git config, which shows the patch diff on bottom of the commit message. Unfortunately the character limit was also applied to the diff, which meant that I got a false-positive lint error almost every time.
This commit is contained in:
@@ -17,6 +17,11 @@ fi
|
||||
|
||||
line_number=0
|
||||
while read -r line; do
|
||||
# break on git cut line, used by git commit --verbose
|
||||
if [[ "$line" == "# ------------------------ >8 ------------------------" ]]; then
|
||||
break
|
||||
fi
|
||||
|
||||
# ignore comment lines
|
||||
[[ "$line" =~ ^#.* ]] && continue
|
||||
|
||||
|
||||
Reference in New Issue
Block a user