Created
May 19, 2014 19:44
-
-
Save ilkerde/4a20350d1021e2b85217 to your computer and use it in GitHub Desktop.
Convert Latin1 to UTF8 in CLI
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 . -type f -iname *.html -exec file --mime-encoding {} \; | grep -Z iso-8859-1 | sed 's/: iso-8859-1//g' | xargs -i{} sh -c 'iconv -f iso-8859-1 -t utf-8 -o "{}".utf8 "{}";mv -f "{}".utf8 "{}";' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment