Last active
December 27, 2015 14:59
-
-
Save jvanja/7344608 to your computer and use it in GitHub Desktop.
Regex for search and replace in between two strings: string 'start' and string 'end', using 'look ahead' and 'look behind'.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(?<=start)(.*)(?=end) // lazy - it will select until LAST occurence | |
(?<=start)(.*?)(?=end) // not lazy - it will select until FIRST occurence |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment