X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?a=blobdiff_plain;f=git-daemon%2Fgit-urlmap;h=80a1f3c00ac052e8682937975444582fd9010f24;hb=9f8946ddeb2b7851502eccb460e5d15845c2fc7e;hp=cf8b55784499a71240ea7052819d62a6b59fdfe5;hpb=e9fec26ad6b6fdbdf77a2422f7b0bdf2eeb5e07b;p=userv-utils.git diff --git a/git-daemon/git-urlmap b/git-daemon/git-urlmap index cf8b557..80a1f3c 100644 --- a/git-daemon/git-urlmap +++ b/git-daemon/git-urlmap @@ -1,46 +1,35 @@ -# Configuration file for the userv git daemon. -# -# This was written by Tony Finch -# You may do anything with it, at your own risk. -# http://creativecommons.org/publicdomain/zero/1.0/ -# -# This is a perl script which is expected to set a few variables -# to locate the requested repository. -# -# REQUEST VARIABLES -# $service - normally "git-upload-pack" -# `git daemon --help` describes other possible services -# $host -# $path -# $uri = git://$host/$path -# $_ = $uri +# Each line is one of: +# +# single-user [/] [] +# matching requests will be handled by +# and unless overridden by handled by +# serving subdirectories of +# +# multi-user [/] +# matching requests are only those those next +# path element starts with ~. The +# request will be handled by and unless +# overridden by will be handled by +# serving subdirectories of +# ( must be a relative path) +# +# repo-regexp +# For per-user service. Subrepos must match this +# regexp, which must contain a single matching +# group which is the filesystem pathname inside +# the . The default is: +# repo-regexp ^(w[-+._0-9A-Za-z]*/?\.git)$ +# +# [no-]require-git-daemon-export-ok +# For per-user service. Default is no-. +# +# Last match, or last setting, wins. +# s may start with ~ + +# here is an example, taken from chiark: # -# CONNECTION VARIABLES -# $client_addr -# $client_port -# $client = [$client_addr]:$client_port -# $server_addr -# $server_port -# $server = [$server_addr]:$server_port +# single-user dotat.at fanf dotat-git +# single-user git.chiark.greenend.org.uk webmaster /u2/git-repos # -# OUTPUT VARIABLES -# $user - who runs the service -# $dir - may be: -# * an absolute path -# * a path relative to the user's home directory -# * equivalently, a path starting ~/ -# $repo - if set, the repository's path is $dir/$repo -# otherwise, the repository's path is just $dir -# $check_export - whether to check for a git-daemon-export-ok file -# (default false) -# $check_repo - whether to restrict the syntax of $repo -# (default true) -# @opts - options for the service command - -if ($path =~ m{^~([^/]*)/(.*)}) { - $user = $1; - $dir = 'public-git'; - $repo = $2; -} - -# end +# multi-user cabal.greenend.org.uk cabal-git +# multi-user git.chiark.greenend.org.uk public-git