Merge pull request #2 from lyoshenka/fixes

Fix highlighting of unicode characters and punctuation, date/time formats, numbers in \G mode.
This commit is contained in:
Alexey Kalinin 2013-11-22 01:08:00 -08:00
commit 1e90cc6e83

80
.grcat
View File

@ -1,40 +1,54 @@
#default word color
#regexp=[\w.,\:\-_/]+
regexp=.+
colours=green
-
#table borders
regexp=[+\-]+[+\-]|[|]
colours=red
-
#data in ( ) and ' '
regexp=\([\w\d,']+\)
colours=white
-
#numeric
regexp=\s[\d\.]+(\s|.$)
colours=yellow
-
#date
regexp=\d{4}-\d{2}-\d{2}
colours=cyan
-
#time
regexp=\d{2}:\d{2}:\d{2}
colours=cyan
-
#IP
regexp=(\d{1,3}\.){3}\d{1,3}(:\d{1,5})?
colours=cyan
-
#schema
regexp=`\w+`
colours=yellow
-
#email
regexp=[\w\.\-_]+@[\w\.\-_]+
colours=magenta
-
#row delimeter when using \G key
regexp=[*]+.+[*]+
count=stop
colours=white
-
#table borders
regexp=[+\-]+[+\-]|[|]
colours=red
-
#default word color
regexp=[\w]+
colours=green
-
#data in ( ) and ' '
regexp=\([\w\d,']+\)
colours=white
-
#numeric
regexp=\s[\d\.]+\s
colours=yellow
-
#column names when using \G key
regexp=\w+:
regexp=^\s*\w+:
colours=white
-
#date
regexp=\d{4}-\d{2}-\d{2}\s\d{2}:\d{2}:\d{2}
colours=cyan
-
#IP
regexp=(\d{1,3}\.){3}\d{1,3}(:\d{1,5})?
colours=cyan
-
#schema
regexp=`\w+`
colours=yellow
-
#email
regexp=[\w\.\-_]+@[\w\.\-_]+
colours=magenta