]> gitweb.ps.run Git - ps-cgit/blobdiff - cgitrc.5.txt
Merge branch 'lh/module-links'
[ps-cgit] / cgitrc.5.txt
index 9a9965b479f38fa7b2947a7ee90087304781daae..b4ad2acb5481e99fc592d400ea70c062f4bd4e75 100644 (file)
@@ -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
@@ -225,7 +230,7 @@ module-link::
        Text which will be used as the formatstring for a hyperlink when a
        submodule is printed in a directory listing. The arguments for the
        formatstring are the path and SHA1 of the submodule commit. Default
-       value: "./?repo=%s&page=commit&id=%s"
+       value: none.
 
 nocache::
        If set to the value "1" caching will be disabled. This settings is
@@ -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:
@@ -406,6 +411,18 @@ repo.logo-link::
        calculated url of the repository index page will be used. Default
        value: global logo-link.
 
+repo.module-link::
+       Text which will be used as the formatstring for a hyperlink when a
+       submodule is printed in a directory listing. The arguments for the
+       formatstring are the path and SHA1 of the submodule commit. Default
+       value: <module-link>
+
+repo.module-link.<path>::
+       Text which will be used as the formatstring for a hyperlink when a
+       submodule with the specified subdirectory path is printed in a
+       directory listing. The only argument for the formatstring is the SHA1
+       of the submodule commit. Default value: none.
+
 repo.max-stats::
        Override the default maximum statistics period. Valid values are equal
        to the values specified for the global "max-stats" setting. Default
@@ -489,7 +506,7 @@ Also, all filters are handed the following environment variables:
 
 If a setting is not defined for a repository and the corresponding global
 setting is also not defined (if applicable), then the corresponding
-environment variable will be an empty string.
+environment variable will be unset.
 
 
 MACRO EXPANSION
@@ -511,6 +528,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 +543,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