[svk-commit] r2688 - branches/safe-pre-commit/utils
nobody at bestpractical.com
nobody at bestpractical.com
Fri Jan 18 11:46:24 EST 2008
Author: clkao
Date: Fri Jan 18 11:46:24 2008
New Revision: 2688
Modified:
branches/safe-pre-commit/utils/forbid-svncommit.pl
Log:
make sure we have svk:notify-commit configured so we don't
shoot ourselves.
Modified: branches/safe-pre-commit/utils/forbid-svncommit.pl
==============================================================================
--- branches/safe-pre-commit/utils/forbid-svncommit.pl (original)
+++ branches/safe-pre-commit/utils/forbid-svncommit.pl Fri Jan 18 11:46:24 2008
@@ -1,9 +1,18 @@
#!/usr/bin/perl -w
use strict;
use SVN::Hook;
+use SVN::Core;
+use SVN::Repos;
+use SVN::Fs;
use Cwd 'abs_path';
my $repospath = shift or die "repospath required.\n";
+$repospath = abs_path($repospath);
+
+my $repos = SVN::Repos::open($repospath) or die "Can't open repository: $@";
+
+my $fs = $repos->fs;
+$fs->change_rev_prop(0, 'svk:notify-commit' => '*');
my $hooks = SVN::Hook->new({ repospath => $repospath});
More information about the svk-commit
mailing list