author | Andy Parkins <andyparkins@gmail.com> | |
Thu, 21 Dec 2006 09:24:17 +0000 (09:24 +0000) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Tue, 26 Dec 2006 20:25:34 +0000 (12:25 -0800) | ||
commit | 59f3e254801648322b2d5cd073ca0cc5009aa2de | |
tree | 58fe625e4c20b9601fffc715545741603dfc7d40 | tree | snapshot |
parent | 7948d7744dfc19d25b6cde1091460fa68733c3d7 | commit | diff |
hooks/commit-msg: add example to add Signed-off-by line to message
After checking to see if the commit message already has the target
signed-off-by (for example in --amend commits), this patch generates a
signed off by line from the repository owner and adds it to the commit
message.
Based on Johannes Schindelin's earlier patch to perform the same
function.
Originally, this was done in the pre-commit hook but Junio pointed out
that the commit-msg hook allows the message to be edited. This has the
aditional advantage that the commit-msg hook gets passed the name of the
message file as a parameter, so it doesn't have to figure out GIT_DIR for
itself.
Signed-off-by: Andy Parkins <andyparkins@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
After checking to see if the commit message already has the target
signed-off-by (for example in --amend commits), this patch generates a
signed off by line from the repository owner and adds it to the commit
message.
Based on Johannes Schindelin's earlier patch to perform the same
function.
Originally, this was done in the pre-commit hook but Junio pointed out
that the commit-msg hook allows the message to be edited. This has the
aditional advantage that the commit-msg hook gets passed the name of the
message file as a parameter, so it doesn't have to figure out GIT_DIR for
itself.
Signed-off-by: Andy Parkins <andyparkins@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
templates/hooks--commit-msg | diff | blob | history |