X-Git-Url: https://gitweb.ps.run/ps-cgit/blobdiff_plain/8149be213f1c8f52b0dbe6c213f6073af57fa954..d889cae811f27a052317ac5aea23890cba414760:/filters/about-formatting.sh diff --git a/filters/about-formatting.sh b/filters/about-formatting.sh index 313a4e6..85daf9c 100755 --- a/filters/about-formatting.sh +++ b/filters/about-formatting.sh @@ -3,7 +3,7 @@ # This may be used with the about-filter or repo.about-filter setting in cgitrc. # It passes formatting of about pages to differing programs, depending on the usage. -# Markdown support requires perl. +# Markdown support requires python and markdown-python. # RestructuredText support requires python and docutils. # Man page support requires groff. @@ -18,8 +18,8 @@ # CGIT_REPO_CLONE_URL ( = repo.clone-url setting ) cd "$(dirname $0)/html-converters/" -case "$(tr '[:upper:]' '[:lower:]' <<<"$1")" in - *.md|*.mkd) exec ./md2html; ;; +case "$(printf '%s' "$1" | tr '[:upper:]' '[:lower:]')" in + *.markdown|*.mdown|*.md|*.mkd) exec ./md2html; ;; *.rst) exec ./rst2html; ;; *.[1-9]) exec ./man2html; ;; *.htm|*.html) exec cat; ;;