Gitolite, how to include .conf file with a relative path?

I'm running a Gitolite server, and I was thinking of having 1 config file per repository.

For now I've this gitolite.conf file:

@php_dev = userA userB
@int_dev = userC
@lead = userD
@admin = @php_dev

repo    gitolite-admin
        RW+     =   @admin

repo    testing
        RW+     =   @all

include "repositories/*.conf"

And then I have the gitolite-admin/conf/repositories/cms/admin/repoA.conf file:

repo    cms/admin/repoA
        RW+     =   @php_dev
        RW      =   @int_dev
        R       =   @lead

When I commit, I only have the following warning:

remote: the following users have no pubkeys:
remote: userC

and that's true, userC doesn't have a pubkey yet. ( I'm just mentionning it in case that matters )

Then I look on server, in the /home/git/repositories/ folder:

git@FX55TMP:~/repositories$ ls -la
total 16
drwx------ 4 git git 4096 2011-04-03 22:16 .
drwxr-xr-x 6 git git 4096 2011-04-03 22:16 ..
drwx------ 8 git git 4096 2011-04-03 23:21 gitolite-admin.git
drwx------ 7 git git 4096 2011-04-03 23:21 testing.git

Their is no cms/admin/ folder that have been auto-created -- as mentionned in the documentation -- , so that let me think that my config file is not loaded.

Did I've made something wrong ?


Solution 1:

You include "repositories/*.conf", but your file is in repositories/cms/admin/repoA.conf. Asterisk wildcards (at least in gitolite) will not match subdirectory components. They refer to the wildcard as a glob in http://sitaramc.github.com/gitolite/doc/gitolite.conf.html, and generally shell globs will only match within the directory they are used.

Since it doesn't find any repositories/*.conf (and thus never your repoA.conf) it will not be creating those repositories.