[vhffs-dev] [585] Added St?\195?\169phane Bauland' s script to adapt existing SVN repositories to commit mail mechanism.

[ Thread Index | Date Index | More vhffs.org/vhffs-dev Archives ]


Revision: 585
Author:   beuss
Date:     2007-04-21 07:43:54 +0000 (Sat, 21 Apr 2007)

Log Message:
-----------
Added St?\195?\169phane Bauland's script to adapt existing SVN repositories to commit mail mechanism.

Modified Paths:
--------------
    trunk/vhffs-compat/Makefile.am

Added Paths:
-----------
    trunk/vhffs-compat/svn-link-4.0.sh


Modified: trunk/vhffs-compat/Makefile.am
===================================================================
--- trunk/vhffs-compat/Makefile.am	2007-04-20 16:56:48 UTC (rev 584)
+++ trunk/vhffs-compat/Makefile.am	2007-04-21 07:43:54 UTC (rev 585)
@@ -4,14 +4,16 @@
 	4.0.sql
 
 compat_SCRIPTS = \
-	updatedb.pl
+	updatedb.pl \
+	svn-link-4.0.sh
 
 # Define the substitution we need to point perl script at correct location
 do_sed = $(SED) --in-place \
 	-e 's,%PERL%,$(PERL),g' \
 	-e 's,'%VHFFS_LIB_DIR%',$(VHFFS_LIBDIR),g' \
 	-e 's,'%VHFFS_BACKEND_DIR%',$(BACKENDDIR),g' \
-	-e 's,'%VHFFS_COMPAT_DIR%',$(compatdir),g'
+	-e 's,'%VHFFS_COMPAT_DIR%',$(compatdir),g' \
+	-e 's,'%VHFFS_BOTS_DIR%',$(BOTSDIR),g'
 
 # Because automake, exec-hook is executed before install-scripts
 # so install-data is after. Here we use a data-hook

Added: trunk/vhffs-compat/svn-link-4.0.sh
===================================================================
--- trunk/vhffs-compat/svn-link-4.0.sh	2007-04-20 16:56:48 UTC (rev 584)
+++ trunk/vhffs-compat/svn-link-4.0.sh	2007-04-21 07:43:54 UTC (rev 585)
@@ -0,0 +1,25 @@
+#!/bin/bash
+
+REPOROOT=$1
+SCRIPTPATH=$2
+
+function help()
+{
+    echo "Usage: $0 /path/to/vhffs/svnroot /path/to/vhffs_post_commit.pl" >&2
+    echo "Example:" >&2
+    echo "  $0 /data/svn/svnroot %VHFFS_BOTS_DIR%/misc/vhffs_post_commit.pl" >&2
+    exit
+}
+
+if ! test $# -eq 2; then
+    echo "*** Error *** $0 takes 2 arguments" >&2
+    help
+fi
+
+for group in `ls $REPOROOT`;
+do
+    for svn in `ls $REPOROOT/$group`;
+    do
+       ln -sf $SCRIPTPATH $REPOROOT"/"$group"/"$svn"/hooks/post-commit"
+    done
+done


Property changes on: trunk/vhffs-compat/svn-link-4.0.sh
___________________________________________________________________
Name: svn:executable
   + *


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/