Created
October 24, 2016 13:23
-
-
Save kleinjm/1ff48b77a228e21ba9d58045d061712b to your computer and use it in GitHub Desktop.
Converts all files in a project directory to .html.haml from .html.erb
This file contains hidden or 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
#!/bin/bash | |
gem install html2haml | |
find . -name \*.erb -print | sed 'p;s/.erb$/.haml/' | xargs -n2 html2haml | |
find . -type f -name '*.html.erb' -delete |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment