diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/subversion/manifests/init.pp | 8 | ||||
-rw-r--r-- | modules/subversion/templates/pre-revprop-change | 15 |
2 files changed, 23 insertions, 0 deletions
diff --git a/modules/subversion/manifests/init.pp b/modules/subversion/manifests/init.pp index 3472099d..4e345618 100644 --- a/modules/subversion/manifests/init.pp +++ b/modules/subversion/manifests/init.pp @@ -55,6 +55,14 @@ class subversion { content => template('subversion/no_empty_message') } + file { "$local_dir/pre-revprop-change": + ensure => present, + owner => root, + group => root, + mode => 755, + content => template('subversion/pre-revprop-change') + } + # TODO : add check for # - ym perl -MYAML -e 'YAML::LoadFile("-");' # - tt ( do not seem to be possible, but this would be great ) diff --git a/modules/subversion/templates/pre-revprop-change b/modules/subversion/templates/pre-revprop-change new file mode 100644 index 00000000..e9b18150 --- /dev/null +++ b/modules/subversion/templates/pre-revprop-change @@ -0,0 +1,15 @@ +#!/bin/sh + +# script taken from svn example hooks + +REPOS="$1" +REV="$2" +USER="$3" +PROPNAME="$4" +ACTION="$5" + +if [ "$ACTION" = "M" -a "$PROPNAME" = "svn:log" ]; then exit 0; fi + +echo "Changing revision properties other than svn:log is prohibited" >&2 +exit 1 + |