Skip to content

Instantly share code, notes, and snippets.

@ihatov08
Created April 2, 2019 08:26
Show Gist options
  • Save ihatov08/36f6f99ce5b71b2660f209793be57f77 to your computer and use it in GitHub Desktop.
Save ihatov08/36f6f99ce5b71b2660f209793be57f77 to your computer and use it in GitHub Desktop.

Revisions

  1. ihatov08 created this gist Apr 2, 2019.
    3 changes: 3 additions & 0 deletions erb_to_haml.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,3 @@
    #!bin/bash
    # *.html.erb -> *.html.haml
    find . -type f -name "*.html.erb" -print0 | while read -r -d '' file; do mv "$file" "${file%%.html.erb}.html.haml";done