20 points

Every day pretty much with Unix tools. Vim, awk, sed, etc.

permalink
report
reply
13 points

Usually many times a day… Even today which have been mostly meetings.

permalink
report
reply

Yesterday. Gotta grep those logs.

permalink
report
reply
9 points

Today.

permalink
report
reply
8 points
*

At least once every few days while coding, usually to do one of the following:

  1. Select multiple things in the same file at the same time without needing to click all over the place

    Normally I use multicursor keyboard shortcuts to select what I want and for the trickier scenarios there are also commands to go through selections one at a time so you can skip certain matches to end up with only what you want.

    But sometimes there are too many false matches that you don’t want to select by hand and that’s where regex comes in handy.

    For instance, finding:

    • parent but not apparent, transparent, parentheses, apparently, transparently
    • test but not latest, fastest, testing, greatest, shortest
    • trie but not entries, retries, countries, retrieve
    • http but not https

    … which can be easily done by searching for a word that doesn’t include a letter immediately before or immediately after: e.g. \Wtest\W.

  2. Search for things across all files that come back with too many results that aren’t relevant

    Basically using the same things above.

  3. Finding something I already know mates a pattern. Like finding all years: \d{4}, finding all versions: \d+\.\d+\.\d+, finding random things that a linter may have missed such as two empty lines touching each other: \n\s*\n\s*\n, etc…

permalink
report
reply

Programming

!programming@programming.dev

Create post

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person’s post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you’re posting long videos try to add in some form of tldr for those who don’t want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



Community stats

  • 3K

    Monthly active users

  • 1.7K

    Posts

  • 28K

    Comments