Mercurial > repos > other > linux
view nanorc.d/sh.nanorc @ 95:e7a2fbd79035
Add XML support
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Mon, 02 Apr 2018 19:36:29 +0100 |
parents | 5f2c5800fa8a |
children |
line wrap: on
line source
## Here is an example for Bourne shell scripts. syntax "sh" "\.sh$" header "^#!.*((ba|da|k|pdk)?sh[-0-9_]*|openrc-run|runscript)" magic "(POSIX|Bourne-Again) shell script.*text" linter dash -n comment "#" icolor cyan "^[0-9A-Z_]+\(\)" color cyan "\<(break|case|continue|do|done|elif|else|esac|exit|fi|for|function|if|in|read|return|select|shift|then|time|until|while)\>" color cyan "\<(declare|eval|exec|export|let|local)[[:space:]]\>" color cyan "[{}():;|`$<>!=&\\]" "(\]|\[)" color cyan "(function )?[a-zA-Z0-9_]+[[:space:]]*\(\)" color cyan "-[Ldefgruwx]\>" color red "-(eq|ne|gt|lt|ge|le|s|n|z)\>" color red "&&|\|\|" color brightblue "\<(awk|cat|cd|ch(grp|mod|own)|cp|echo|env|grep|install|ln|make|mkdir|mv|popd|printf|pushd|rm|rmdir|sed|set|tar|touch|umask|unset)\>" # Basic variable names (no braces). color magenta "\$[-0-9@*#?$!]" "\$[[:alpha:]_][[:alnum:]_]*" # More complicated variable names; handles braces and replacements and arrays. color magenta "\$\{[#!]?([-@*#?$!]|[0-9]+|[[:alpha:]_][[:alnum:]_]*)(\[([[:space:]]*[[:alnum:]_]+[[:space:]]*|@)\])?(([#%/]|:?[-=?+])[^}]*\}|\[|\})" # Strings. color yellow ""(\\.|[^"])*"" "'(\\.|[^'])*'" # Comments. color green "(^|[[:space:]])#.*$" # Trailing whitespace. color ,green "[[:space:]]+$"