Skip to content

Instantly share code, notes, and snippets.

@IvanTorresEdge
Created January 13, 2012 04:06
Show Gist options
  • Save IvanTorresEdge/1604642 to your computer and use it in GitHub Desktop.
Save IvanTorresEdge/1604642 to your computer and use it in GitHub Desktop.
Convert all my templates from ERB to HAML
#!/usr/bin/env sh
for f in `find app/views/ -name "*.erb"`
do
echo "processing $f"
out=`echo $f | sed "s/\.erb$/\.haml/"`
html2haml $f > $out
git add $out
git rm $f
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment