简体   繁体   中英

IntelliJ IDEA Console Folding with Wildcards?

Short Question: Can I specify wildcards for custom console folding? If so, what is the syntax?

Long Question: IntelliJ has a really nifty plugin (that comes built in) which allows you to fold lines in console output (and specify a blacklist/whitelist of when or when not to do this)

控制台折叠

However I am unsure how (if it's even possible) to specify a wildcard character. a lot of lines begin with a timestamp, like so

1, Jan, 2012, 10:00:00,000 DEBUG

Which i'd like to fold, by DEBUG, using something like

* DEBUG

I know I could restrict the log level to INFO only, but these lines are useful if a test fails, and then I can expand them at will.

Is there a way to do this, or should I start looking for the IntelliJ feature request page?

You shouldn't use wildcards at all. When you add a new folding pattern you get a prompt saying:

Enter a substring of a console line you'd like to see folded:

折叠图案

Notice that it says "substring". Try to just write "DEBUG" there and see if it works.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM