Created
June 23, 2017 16:23
-
-
Save emafriedrich/f380eec94b67fcc7b5c993d96469b670 to your computer and use it in GitHub Desktop.
Replace images src with erb <%= image_tag(src) %> in sublime text
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
Search all images paths on file | |
\/[\w:-]*\.(png|jpg?e) | |
replace with | |
<%=image_path('${0}')%> | |
ej: | |
<img src="/assets/1.png" > | |
transform to | |
<img src="<%=image_path('/assets/1.png')%>"> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment