rcs hook setup for the two I know
authorJoey Hess <joey@kodama.kitenet.net>
Sun, 27 Jul 2008 05:50:43 +0000 (01:50 -0400)
committerJoey Hess <joey@kodama.kitenet.net>
Sun, 27 Jul 2008 05:50:43 +0000 (01:50 -0400)
IkiWiki/Setup/Automator.pm

index 8cf158db2aafaaedb80143e28df7055257391783..060a8be56c2872e5b7f9c0620dbd9caffdff067b 100644 (file)
@@ -56,7 +56,23 @@ sub import (@) { #{{{
                "--url", $setup{url},
                "--cgiurl", $setup{cgiurl}
        );
-       push @params, "--rcs", $setup{rcs} if $setup{rcs};
+       if ($setup{rcs}) {
+               push @params, "--rcs", $setup{rcs};
+               if ($setup{rcs} eq 'git') {
+                       push @params, "--set", "git_wrapper=".
+                               $setup{repository}."/hooks/post-update";
+               }
+               elsif ($setup{rcs} eq 'svn') {
+                       push @params, "--set", "svn_wrapper=".
+                               $setup{repository}."/hooks/post-commit";
+               }
+               elsif ($setup{rcs} eq 'bzr') {
+                       # TODO
+               }
+               elsif ($setup{rcs} eq 'mercurial') {
+                       # TODO
+               }
+       }
        if (exists $setup{add_plugins}) {
                foreach my $plugin (@{$setup{add_plugins}}) {
                        push @params, "--plugin", $plugin;