Last active
April 25, 2016 09:52
-
-
Save baslie/fa58acd5d87e6456652733b88b65f293 to your computer and use it in GitHub Desktop.
Sublime Text: Regular Expressions
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
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++ | |
FIND & REPLACE | |
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++ | |
Example: | |
/*------------------------------------------ | |
* Comment | |
*------------------------------------------*/ | |
Regex: | |
(^[\s]*?\/\/.*)|(/\*[\s\S]+?\*/) | |
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++ | |
Example: | |
<!-- Comment --> | |
Regex: | |
(?s)<!--.*?--> | |
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++ | |
Example: | |
"Empty line with spaces" | |
Regex: | |
^[\s]*?[\n\r]+ | |
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment