Skip to content

Instantly share code, notes, and snippets.

@junkdog
Created October 21, 2022 07:47
Show Gist options
  • Save junkdog/6ee3aab493b1546d66754aa510548e2d to your computer and use it in GitHub Desktop.
Save junkdog/6ee3aab493b1546d66754aa510548e2d to your computer and use it in GitHub Desktop.
grc stuff
# VERBOSE
regexp=\sV/[\w.]+:
colours=bold black
-
# DEBUG
regexp=\sD/[\w.]+:
colours=green
-
# INFO
regexp=\sI/[\w.]+:
colours=green bold
-
# WARN
regexp=\sW/[\w.]+:
colours=yellow
-
# ERROR
regexp=\sE/[\w.]+:
colours=red
-
# strings
regexp="[^"]*"
colours=magenta
count=more
-
# saved under ~/.grc/
# tabs to spaces
regexp=\t
replace=
count=more
-
regexp=\s\d*\s*\d*\s*V\s
colours=dark white
-
# DEBUG
regexp=\sDEBUG\s
colours=green
-
regexp=\s\d*\s*\d*\s*D\s
colours=green
-
# INFO
regexp=\sINFO\s
colours=green bold
-
# WARN
regexp=\sWARN\s
colours=yellow
-
# ERROR
regexp=\sERROR\s
colours=red
-
# exceptions
regexp=\s([a-z.]+\.[\w\d]+(Exception|Error):)
colours=none, red reverse, red reverse
count=once
-
regexp=\s+at\s+([\w\d./]+)(\.?[\w$]+)\.([^.]+)\(
colours=dark white, dark green, green, bold green
count=once
-
# strings
regexp="[^"]*"
colours=magenta
count=more
-
regexp=("[^"]*):("[^"]*")
colours=bold magenta, magenta, yellow
count=more
-
regexp=("[^"]*):((null|true|false|[\d]+\.?\d*))
colours=bold magenta, magenta, bold yellow
count=more
-
regexp=([\d\w]+)=([^ ]*)
colours=none, cyan, bold white
count=more
-
regexp=([a-z][\w\d]+) = ([^ ]*)
colours=none, cyan, bold
count=more
-
# events
regexp=[A-Z][\w\d]+Event[^\w]
colours=bold cyan
count=more
-
# commands
regexp=[A-Z][\w\d]+Command[^\w]
colours=bold yellow
count=more
-
# queries
regexp=[A-Z][\w\d]+Query[^\w]
colours=bold blue
count=more
-
# projections
regexp=[A-Z][\w\d]+Projection[^\w]
colours=green
count=more
-
# uuid
regexp=([\w\d]{8})-([\w\d]{4})-([\w\d]{4})-([\w\d]{4})-([\w\d]{12})
colours=magenta
count=more
-
# http methods
regexp=(GET|POST|PUT|PATCH|DELETE)\s+/[^\]]+
colours=bold white
count=more
-
# http/s
regexp=https?://[^\s]*
colours=bold white
count=more
-
regexp=^\s+([a-z][\w\d]+) = (.*)$
colours=none, cyan, bold
count=once
-
# (), {}, []
regexp=[()\[\]{}]
colours=yellow
count=more
-
# , and "
regexp=[,"]
colours=default
count=more
-
# timing
regexp=[\s(](\d+)\s?(ms)
colours=none, bold yellow, yellow
count=more
-
### hh:mm:ss.SSS
regexp=\d{2}:\d{2}:\d{2}\.(\d{3})
colours=bold black on_white, black on_white
count=once
-
### mm:ss.SSS
regexp=\d{2}:\d{2}\.(\d{3})
colours=bold black on_white, black on_white
count=once
-
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment