Skip to content

Instantly share code, notes, and snippets.

@robdimarco
Created February 12, 2012 18:51
Show Gist options
  • Save robdimarco/1810220 to your computer and use it in GitHub Desktop.
Save robdimarco/1810220 to your computer and use it in GitHub Desktop.
Bash one-liner to move all ERB files to HAML using html haml
for f in `find . -name '*.erb'`; do
new_f=`dirname $f`/`basename $f | sed s/erb/haml/`;
html2haml $f > $new_f;
git rm $f;
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment