Created
July 29, 2014 12:02
-
-
Save linko/5006a2748d449acf48ee to your computer and use it in GitHub Desktop.
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
find app/views/ -name '*.html.haml' | while read p; do haml-i18n-extractor $p -n -y config/locales/views/$(echo $p | sed 's/app\/views\///g' | sed 's/.html.haml/.yml/g') && echo $p; done | |
remember to put this to application.rb: | |
config.i18n.load_path += Dir[Rails.root.join('config', 'locales', '**', '*.{rb,yml}')] | |
after that might need to run | |
grep -Rl "'\"" config/locales/ | while read p; do sed -i "s/'\"/'/g" $p && sed -i "s/\"'/'/g" $p; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment