aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSitaram Chamarty <sitaram@atc.tcs.com>2012-02-03 06:56:49 +0530
committerSitaram Chamarty <sitaram@atc.tcs.com>2012-02-03 14:03:57 +0530
commit1363534d8d01323bb084c13d005ff0993ce19d57 (patch)
tree7f3ffb124abbd2055dbff364fed933ff4bd6936c
parentallow comments in setperms inputs (diff)
downloadgitolite-gentoo-1363534d8d01323bb084c13d005ff0993ce19d57.tar.gz
gitolite-gentoo-1363534d8d01323bb084c13d005ff0993ce19d57.tar.bz2
gitolite-gentoo-1363534d8d01323bb084c13d005ff0993ce19d57.zip
honor GL_NO_DAEMON_NO_GITWEB for wild repos also
Thanks to Kacper Kornet for catching this... (by the way, there's a simple workaround if you are affected by this but can't upgrade to this commit or later: just create an empty $PROJECTS_LIST file, which is by default ~/projects.list)
-rw-r--r--doc/big-config.mkd13
-rw-r--r--src/gitolite.pm6
2 files changed, 13 insertions, 6 deletions
diff --git a/doc/big-config.mkd b/doc/big-config.mkd
index 2aaa61a..31059ed 100644
--- a/doc/big-config.mkd
+++ b/doc/big-config.mkd
@@ -2,8 +2,9 @@
This document is just background info; you don't actually need to read the
whole thing if you don't care. All you need to do is set `BIG_CONFIG` to 1 in
-the rc file and you're done. If you have no use for gitweb and daemon, you
-can save even more time by setting `GL_NO_DAEMON_NO_GITWEB`.
+the rc file and you're done. If you have no use for gitweb, git-daemon, or
+[git config][rsgc], you can save even more time by setting
+`GL_NO_DAEMON_NO_GITWEB`.
Finally, if you're *really* an expert (or your initials are "JK"), you can
even set `GL_NO_CREATE_REPOS` and `GL_NO_SETUP_AUTHKEYS`. However, be warned
@@ -147,10 +148,10 @@ first one):
`GL_NO_DAEMON_NO_GITWEB` is a very useful optimisation that you *must* enable
if you *do* have a large number of repositories, and do *not* use gitolite's
-support for gitweb or git-daemon access (see "[this][gwd]" for details). This will save a
-lot of time when you push the gitolite-admin repo with changes. This variable
-also controls whether "git config" lines (such as `config hooks.emailprefix =
-"[gitolite]"`) will be processed or not.
+support for gitweb or git-daemon access (see "[this][gwd]" for details). This
+will save a lot of time when you push the gitolite-admin repo with changes.
+This variable also controls whether "git config" lines (such as `config
+hooks.emailprefix = "[gitolite]"`) will be processed or not.
You should be a lot more careful with `GL_NO_CREATE_REPOS` and
`GL_NO_SETUP_AUTHKEYS`. These are meant for installations where some backend
diff --git a/src/gitolite.pm b/src/gitolite.pm
index acd7ff0..062706f 100644
--- a/src/gitolite.pm
+++ b/src/gitolite.pm
@@ -443,6 +443,8 @@ sub get_set_desc
sub setup_git_configs
{
+ return if $GL_NO_DAEMON_NO_GITWEB;
+
my ($repo, $git_configs_p) = @_;
# new_wild calls us without checking!
@@ -476,6 +478,8 @@ sub setup_git_configs
my $export_ok = "git-daemon-export-ok";
sub setup_daemon_access
{
+ return if $GL_NO_DAEMON_NO_GITWEB;
+
my $repo = shift;
if (can_read($repo, 'daemon')) {
@@ -507,6 +511,8 @@ sub setup_web_access {
}
sub add_del_web_access {
+ return if $GL_NO_DAEMON_NO_GITWEB;
+
# input is a repo name. Code could simply use `can_read($repo, 'gitweb')`
# to determine whether to add or delete the repo from web access.
# However, "desc" also factors into this so we have think about this.