From b3c55f334acfd073ad3bac0ad1182148cab498c0 Mon Sep 17 00:00:00 2001 From: Stephen Haberman Date: Tue, 11 Nov 2008 15:35:24 -0600 Subject: [PATCH] Use a config variable for where sendmail is at. --- server/post-receive-email | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/server/post-receive-email b/server/post-receive-email index 3cf8d17..1fdecc8 100755 --- a/server/post-receive-email +++ b/server/post-receive-email @@ -35,6 +35,8 @@ # hooks.post-receive-email.envelopesender # If set then the -f option is passed to sendmail to allow the envelope # sender address to be set +# hooks.post-receive-email.sendmail +# The path to sendmail, e.g. /usr/sbin/sendmail or /bin/msmtp # # Notes # ----- @@ -434,10 +436,9 @@ generate_delete_ltag_email() send_mail() { if [ -n "$envelopesender" ] ; then - /usr/sbin/sendmail -t -f "$envelopesender" + $sendmail -t -f "$envelopesender" else - # /usr/sbin/sendmail -t - /home/BIPFS/shaberman/local/bin/msmtp -t + $sendmail -t fi } @@ -466,6 +467,7 @@ announcerecipients=$(git config hooks.post-receive-email.announcelist) envelopesender=$(git config hooks.post-receive-email.envelopesender) emailprefix="[$projectdesc]" debug=$(git config hooks.post-receive-email.debug) +sendmail=$(git config hooks.post-receive-email.sendmail) # --- Main loop # Allow dual mode: run from the command line just like the update hook, or -- 2.39.5