thierryc / Sketch-Find-And-Replace

Sketch plugin to do a find and replace on text within layers
Apache License 2.0
711 stars 37 forks source link

Trying to use Regex to replace anything after a keyword #69

Open mattspencer opened 6 years ago

mattspencer commented 6 years ago

This plugin is a life saver! (especially using regex "^.*$" to replace anything!)

As a designer, I'm not very good at Regex and I've been working with a dev who is, and we can get the following regex to work on https://regex101.com/ but not in this plugin:

(?<=KEYWORD).*$

example string: "select anything after this KEYWORD so that it can be replaced"

I am trying to replace any text that comes after a given keyword.

thierryc commented 6 years ago

I keep you posted

thierryc commented 5 years ago

Find

(KEYWORD).*

Replace by

$1 Hobby

for exemple

image