mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-05 22:20:24 -08:00
; Move Markdown quotation detection to commit-msg hook
* build-aux/git-hooks/prepare-commit-msg: Don't detect markdown quotes here... * build-aux/git-hooks/commit-msg: but here, to intercept interactively composed log messages.
This commit is contained in:
parent
d80ac0fbaa
commit
ba6779ab2a
2 changed files with 5 additions and 4 deletions
|
|
@ -92,6 +92,11 @@ exec $awk \
|
||||||
status = 1
|
status = 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/(^|[^\\])`[^'\''`]+`/ {
|
||||||
|
print "Markdown-style quotes in commit message"
|
||||||
|
status = 1
|
||||||
|
}
|
||||||
|
|
||||||
nlines == 0 && $0 !~ non_space { next }
|
nlines == 0 && $0 !~ non_space { next }
|
||||||
|
|
||||||
{ nlines++ }
|
{ nlines++ }
|
||||||
|
|
|
||||||
|
|
@ -40,10 +40,6 @@ exec $awk "
|
||||||
print \"'Signed-off-by:' in commit message\"
|
print \"'Signed-off-by:' in commit message\"
|
||||||
status = 1
|
status = 1
|
||||||
}
|
}
|
||||||
/(^|[^\\\\])\`[^'\`]+\`/ {
|
|
||||||
print \"Markdown-style quotes in commit message\"
|
|
||||||
status = 1
|
|
||||||
}
|
|
||||||
END {
|
END {
|
||||||
if (status != 0) {
|
if (status != 0) {
|
||||||
print \"Commit aborted; please see the file 'CONTRIBUTE'\"
|
print \"Commit aborted; please see the file 'CONTRIBUTE'\"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue