about summary refs log tree commit diff
path: root/cgitrc.5.txt
diff options
context:
space:
mode:
authorLars Hjemli <hjemli@gmail.com>2011-06-13 23:05:10 +0000
committerLars Hjemli <hjemli@gmail.com>2011-06-13 23:05:10 +0000
commit1b1bf635b59a349a9238a1d63a21d03d9949e185 (patch)
tree78d1501781d72f0698f673e9c44450e32118d843 /cgitrc.5.txt
parentcgitrc.5.txt: reformat the "FILTER API" section (diff)
parentcgit.c: add 'clone-url' setting with support for macro expansion (diff)
downloadcgit-pink-1b1bf635b59a349a9238a1d63a21d03d9949e185.tar.gz
cgit-pink-1b1bf635b59a349a9238a1d63a21d03d9949e185.zip
Merge branch 'lh/clone-url'
Diffstat (limited to '')
-rw-r--r--cgitrc.5.txt17
1 files changed, 14 insertions, 3 deletions
diff --git a/cgitrc.5.txt b/cgitrc.5.txt
index 9a9965b..5ba8134 100644
--- a/cgitrc.5.txt
+++ b/cgitrc.5.txt
@@ -76,6 +76,11 @@ clone-prefix::
 	setting is only used if `repo.clone-url` is unspecified. Default value:
 	none.
 
+clone-url::
+	Space-separated list of clone-url templates. This setting is only
+	used if `repo.clone-url` is unspecified. Default value: none. See
+	also: "MACRO EXPANSION", "FILTER API".
+
 commit-filter::
 	Specifies a command which will be invoked to format commit messages.
 	The command will get the message on its STDIN, and the STDOUT from the
@@ -363,7 +368,7 @@ repo.about-filter::
 
 repo.clone-url::
 	A list of space-separated urls which can be used to clone this repo.
-	Default value: none.
+	Default value: none. See also: "MACRO EXPANSION".
 
 repo.commit-filter::
 	Override the default commit-filter. Default value: none. See also:
@@ -511,6 +516,12 @@ can be accomplished by adding the following line to /etc/cgitrc:
 
 	include=/etc/cgitrc.d/$HTTP_HOST
 
+The following options are expanded during request processing, and support
+the environment variables defined in "FILTER API":
+
+- clone-url
+- repo.clone-url
+
 
 EXAMPLE CGITRC FILE
 -------------------
@@ -520,8 +531,8 @@ EXAMPLE CGITRC FILE
 cache-size=1000
 
 
-# Specify some default clone prefixes
-clone-prefix=git://example.com ssh://example.com/pub/git http://example.com/git
+# Specify some default clone urls using macro expansion
+clone-url=git://foo.org/$CGIT_REPO_URL git@foo.org:$CGIT_REPO_URL
 
 # Specify the css url
 css=/css/cgit.css