]> git.droids-corp.org - git-central.git/commitdiff
Use a config variable for where sendmail is at.
authorStephen Haberman <stephen@exigencecorp.com>
Tue, 11 Nov 2008 21:35:24 +0000 (15:35 -0600)
committerStephen Haberman <stephen@exigencecorp.com>
Tue, 11 Nov 2008 21:37:07 +0000 (15:37 -0600)
server/post-receive-email

index 3cf8d17e3f00f4947b4bca61f1536cb922b3aa1a..1fdecc8d6d37717bc3db5e382de7a667fa495bc4 100755 (executable)
@@ -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