ryu1kn / vscode-text-marker

Visual Studio Code Extension. Select text in your code and mark all matches. The marking colour is configurable
https://marketplace.visualstudio.com/items?itemName=ryu1kn.text-marker
MIT License
87 stars 17 forks source link

Make `^` and `$` useful #82

Open elibarzilay opened 1 year ago

elibarzilay commented 1 year ago

The default mode for ^ and $ make them pretty much useless for highlights (unless you really want something anchored at the beginning/end).

If the regexp flag included m by default (though the above is useless enough that I don't think there's a need to make it an option), you'd be able to do highlights based on the beginning/end of lines.

elibarzilay commented 1 year ago

Two supporting cases: Emacs defaults to this, which makes sense in the context of an editor; regex101.com turns on the m flag by default since it's common to try a pattern against each line.