Skip to content

use regex library for recursion support#117

Open
solaris007 wants to merge 2 commits intogarabik:masterfrom
solaris007:grc-regex-recursion
Open

use regex library for recursion support#117
solaris007 wants to merge 2 commits intogarabik:masterfrom
solaris007:grc-regex-recursion

Conversation

@solaris007
Copy link

for recursion support it would be awesome to use the regex instead of std lib.
this would introduce a pip dependency though. not sure how to handle this?

recursion support would be nice to capture and color nested parenthesis lines, e.g.:
27.03.2019 10:42:27.275 *INFO* [FelixStartLevel [Thread-232]] org.apache.sling.commons.threads.impl.DefaultThreadPool Thread pool [DAM Transporter] initialized.

Using regex: \[([^\[\]]+|(?R))*\]

Which matches: [FelixStartLevel [Thread-232]] and [DAM Transporter]

@garabik
Copy link
Owner

garabik commented Jul 24, 2019

Adding conditional import of regex depending on module availability is easy and I might just do it - I am just a bit concerned that grc fails when using such an incompatible config file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants