From c8954a4039797c303880ea557a07198a9166bd8b Mon Sep 17 00:00:00 2001 From: Olivier Matz Date: Tue, 19 Feb 2013 11:05:33 +0100 Subject: [PATCH] post-receive-delivery: add a deliver command Signed-off-by: Olivier Matz --- server/post-receive-delivery | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/server/post-receive-delivery b/server/post-receive-delivery index 4726561..096ff87 100755 --- a/server/post-receive-delivery +++ b/server/post-receive-delivery @@ -8,7 +8,8 @@ # # This hook clone and pull the repoditory each time a commit is pushed # in the tree. Each branch will be delivered in -# ${GIT_DELIVER_DIRECTORY}/branch. +# ${GIT_DELIVER_DIRECTORY}/branch. If ${GIT_DELIVER_COMMAND} is set, +# this command will be executed in the delivery directory. # ---------------------------- Functions @@ -60,6 +61,11 @@ generate_delivery() unset GIT_DIR git pull --rebase fi + + if [ ! -z "${GIT_DELIVER_COMMAND}" ]; then + cd ${dstdir} + ${GIT_DELIVER_COMMAND} + fi } # ---------------------------- main() -- 2.39.5