From 6cbe4a99af693c7ff876a42354ec438c72579f21 Mon Sep 17 00:00:00 2001 From: yzzyx Date: Fri, 24 Apr 2020 09:22:09 -0500 Subject: [PATCH] Add support for Gophermap and Gemini markdown files --- gemini.nanorc | 21 +++++++++++++++++++++ gophermap.nanorc | 45 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 66 insertions(+) create mode 100644 gemini.nanorc create mode 100644 gophermap.nanorc diff --git a/gemini.nanorc b/gemini.nanorc new file mode 100644 index 0000000..ac8f9d4 --- /dev/null +++ b/gemini.nanorc @@ -0,0 +1,21 @@ +## syntax highlighting for gemini:// markup language + +syntax gemini "\.(gemini|gmi)$" + +# Heading levels +color brightgreen "^#.*" +color brightcyan "^##.*" +color brightmagenta "^###.*" + +# Link Text +color brightred "^=>\s*\S+\s+.*" +# Link URL +color green "^=>\s*\S+" +# Link Prefix +color yellow "^=>" + +# Bullet Lists +color brightblue "^\*.*" + +# Monospaced Blocks +color white,black start="^```" end="^```" diff --git a/gophermap.nanorc b/gophermap.nanorc new file mode 100644 index 0000000..7c868e2 --- /dev/null +++ b/gophermap.nanorc @@ -0,0 +1,45 @@ +## syntax for gophernicus gophermaps + +syntax gophermap "\.(gophermap|gph)$" + + +# Port Numbers +color yellow "^.[ -~]*.[ -~]*.[ -~]*.[ -~]+" + +# Domains +color red "^.[ -~]*.[ -~]*.[ -~]+" + +# Resource Path (no directories) +color green "^[^1][ -~]*.[ -~]*" + +# Directories (w/ Name) +color brightmagenta "^1[ -~]*.[ -~]*" + +# Names +color brightblue "^[ -~]+." + +# Directories (w/o Name) +color brightyellow "^1[ -~]+.$" + +# URLs +color brightcyan "URL:.*" + + +# Types + +# General +color magenta "^." + +# HTML & Interactive Content +color brightcyan "^(h|7|8)" + +# Info Text +color cyan "^i.*" +color cyan "^[ -~]*$" +color blue "^i" + +# Special Tags & Characters +color brightgreen "^(!|-|:|~|%|=|\*|\.).*" + +# Comments +color white,blue "#.*"