summaryrefslogtreecommitdiff
path: root/etc/cgitrc
diff options
context:
space:
mode:
Diffstat (limited to 'etc/cgitrc')
-rw-r--r--etc/cgitrc29
1 files changed, 29 insertions, 0 deletions
diff --git a/etc/cgitrc b/etc/cgitrc
new file mode 100644
index 0000000..003d7a2
--- /dev/null
+++ b/etc/cgitrc
@@ -0,0 +1,29 @@
+#
+# cgit config
+# see cgitrc(5) for details
+
+# Depends: cmark highlight
+
+css=/cgit-feature/feature.css
+logo=/cgit-css/cgit.png
+
+remove-suffix=1
+
+clone-url=git://$HTTP_HOST/$CGIT_REPO_URL https://$HTTP_HOST$SCRIPT_NAME/$CGIT_REPO_URL http://$HTTP_HOST$SCRIPT_NAME/$CGIT_REPO_URL
+
+# (ab)use source filter to parse markdown as html,
+# with line-numbered + highlighted plaintext only as fallback
+# TODO: add anchor to line-numbering:
+# <li style='list-style-type:none'><a id='n2' href='#n2'>2</a>
+# TODO: hide anchor except in :hover mode:
+# <li><a id='n2' href='#n2'>ยง</a>
+enable-tree-linenumbers=0
+source-filter=/usr/local/share/feature/source-hosting/script/syntax-highlighting.sh
+
+about-filter=/usr/local/share/feature/source-hosting/script/about-formatting.sh
+readme=:README.md
+
+cache-size=1000
+
+# must be last!
+scan-path=$DOCUMENT_ROOT