Add Nano tool - user-friendly text editor
[tomato.git] / release / src / router / nano / doc / syntax / awk.nanorc
blob696ab6ad727c017ea40cdde4cb2771f26c07049e
1 ## Here is an example for awk.
2 ##
3 syntax "awk" "\.awk$"
4 ## records
5 icolor brightred "\$[0-9A-Z_!@#$*?-]+"
6 ## awk-set variables
7 color red "\<(ARGC|ARGIND|ARGV|BINMODE|CONVFMT|ENVIRON|ERRNO|FIELDWIDTHS)\>"
8 color red "\<(FILENAME|FNR|FS|IGNORECASE|LINT|NF|NR|OFMT|OFS|ORS)\>"
9 color red "\<(PROCINFO|RS|RT|RSTART|RLENGTH|SUBSEP|TEXTDOMAIN)\>"
10 ## function declarations and special patterns
11 color brightgreen "\<(function|extension|BEGIN|END)\>"
12 ## operators
13 color green "(\{|\}|\(|\)|\;|\]|\[|\\|<|>|!|=|&|\+|-|\*|%|/|\?:|\^|\|)"
14 ## flow control
15 color brightyellow "\<(for|if|while|do|else|in|delete|exit)\>"
16 color brightyellow "\<(break|continue|return)\>"
17 ## I/O statements
18 color brightgreen "\<(close|getline|next|nextfile|print|printf)\>"
19 color brightgreen "\<(system|fflush)\>"
20 ## standard functions
21 color magenta "\<(atan2|cos|exp|int|log|rand|sin|sqrt|srand)\>"
22 color magenta "\<(asort|asorti|gensub|gsub|index|length|match)\>"
23 color magenta "\<(split|sprintf|strtonum|sub|substr|tolower|toupper)\>"
24 color magenta "\<(mktime|strftime|systime)\>"
25 color magenta "\<(and|compl|lshift|or|rshift|xor)\>"
26 color magenta "\<(bindtextdomain|dcgettext|dcngettext)\>"
29 ## String highlighting.  You will in general want your comments and
30 ## strings to come last, because syntax highlighting rules will be
31 ## applied in the order they are read in.
32 color brightyellow "<[^=        ]*>" ""(\\.|[^"])*""
34 ## Comment highlighting
35 color brightblue "(^|[[:space:]])#.*$"
37 ## Trailing whitespace
38 color ,green "[[:space:]]+$"