Merge branch 'master' into git-anon
authorJoey Hess <joey@kodama.kitenet.net>
Thu, 23 Oct 2008 18:09:01 +0000 (14:09 -0400)
committerJoey Hess <joey@kodama.kitenet.net>
Thu, 23 Oct 2008 18:09:01 +0000 (14:09 -0400)
1  2 
ikiwiki.in

diff --combined ikiwiki.in
index 873bde0df49d68d0fe51e18b6ee11bc2ea4f0378,fd21b49112527343c6f63e9eae88f7506a9eb134..22addb46337724eecb2e50b2642c76f73d92e8bb
@@@ -118,6 -118,12 +118,12 @@@ sub getconfig () { #{{
                        error("WRAPPED_OPTIONS: $@");
                }
                delete $ENV{WRAPPED_OPTIONS};
+               # optimisation for no-op post_commit 
+               if ($config{post_commit} && ! commit_hook_enabled()) {
+                       exit 0;
+               }
                loadplugins();
                checkconfig();
        }
@@@ -183,9 -189,6 +189,9 @@@ sub main () { #{{
        elsif ($config{post_commit} && ! commit_hook_enabled()) {
                # do nothing
        }
 +      elsif ($config{test_receive}) {
 +              rcs_test_receive();
 +      }
        else {
                if ($config{rebuild}) {
                        debug(gettext("rebuilding wiki.."));