[Mageia-sysadm] [304] implement the commit mail part

root at mageia.org root at mageia.org
Fri Nov 19 01:24:21 CET 2010


Revision: 304
Author:   misc
Date:     2010-11-19 01:24:21 +0100 (Fri, 19 Nov 2010)
Log Message:
-----------
implement the commit mail part

Modified Paths:
--------------
    puppet/modules/subversion/manifests/init.pp

Added Paths:
-----------
    puppet/modules/subversion/templates/hook_sendmail.pl

Modified: puppet/modules/subversion/manifests/init.pp
===================================================================
--- puppet/modules/subversion/manifests/init.pp	2010-11-19 00:24:19 UTC (rev 303)
+++ puppet/modules/subversion/manifests/init.pp	2010-11-19 00:24:21 UTC (rev 304)
@@ -83,6 +83,15 @@
             mode => 755,
         }
 
+        if $commit_mail {
+            file { "$name/hooks/post-commit.d/send_mail":
+                ensure => present,
+                owner => root,
+                group => root,
+                mode => 755,
+                content => template("subversion/hook_sendmail.pl")
+            }
+        }  
     
     }   
 

Added: puppet/modules/subversion/templates/hook_sendmail.pl
===================================================================
--- puppet/modules/subversion/templates/hook_sendmail.pl	                        (rev 0)
+++ puppet/modules/subversion/templates/hook_sendmail.pl	2010-11-19 00:24:21 UTC (rev 304)
@@ -0,0 +1,13 @@
+#!/usr/bin/perl -MSVN::Notify::Config=$0
+--- #YAML:1.0
+
+'':
+  PATH: "/usr/bin:/usr/local/bin"
+  handler: Alternative
+  alternative: HTML::ColorDiff
+  with-diff: 1
+  to:
+<% commit_mail.each do |mail|  %>
+    - <%= mail %>
+<% end %>
+  from: root@<%= domain %>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/mageia-sysadm/attachments/20101119/ec588584/attachment-0001.html>


More information about the Mageia-sysadm mailing list