From 08aa81a2d48ec93f6d3d581857ba6bcdc079bd43 Mon Sep 17 00:00:00 2001 From: Georg Date: Tue, 3 Aug 2021 22:06:32 +0200 Subject: Markup and Metrics Signed-off-by: Georg --- Gitea/app.ini | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) (limited to 'Gitea') diff --git a/Gitea/app.ini b/Gitea/app.ini index df752e3..c082159 100644 --- a/Gitea/app.ini +++ b/Gitea/app.ini @@ -76,3 +76,53 @@ MODE = file LEVEL = info ROOT_PATH = /var/log/gitea/ +[metrics] +ENABLED=true +TOKEN=$METRICSTOKEN + +[markup.asciidoc] +ENABLED = true +FILE_EXTENSIONS = .adoc,.asciidoc +RENDER_COMMAND = "asciidoctor -s -a showtitle --out-file=- -" +; Input is not a standard input but a file +IS_INPUT_FILE = false + +[markup.jupyter] +ENABLED = true +FILE_EXTENSIONS = .ipynb +RENDER_COMMAND = "jupyter nbconvert --stdin --stdout --to html --template basic" +IS_INPUT_FILE = false + +[markup.restructuredtext] +ENABLED = true +FILE_EXTENSIONS = .rst +RENDER_COMMAND = "timeout 30s pandoc +RTS -M512M -RTS -f rst" +IS_INPUT_FILE = false + +[markup.sanitizer.TeX] +; Pandoc renders TeX segments as s with the "math" class, optionally +; with "inline" or "display" classes depending on context. +ELEMENT = span +ALLOW_ATTR = class +REGEXP = ^\s*((math(\s+|$)|inline(\s+|$)|display(\s+|$)))+ + +[markup.markdown] +ENABLED = true +FILE_EXTENSIONS = .md,.markdown +RENDER_COMMAND = pandoc -f markdown -t html --katex + +[markup.docx] +ENABLED = true +FILE_EXTENSIONS = .docx +RENDER_COMMAND = "pandoc --from docx --to html --self-contained --template /path/to/basic.html" + +[markup.sanitizer.docx.img] +ALLOW_DATA_URI_IMAGES = true + +[markup.jupyter] +ENABLED = true +FILE_EXTENSIONS = .ipynb +RENDER_COMMAND = "jupyter-nbconvert --stdin --stdout --to html --template basic" + +[markup.sanitizer.jupyter.img] +ALLOW_DATA_URI_IMAGES = true -- cgit v1.2.3