Created
May 15, 2018 21:54
-
-
Save ryanmeasel/10048eed7277cb223afc4b69298d79c6 to your computer and use it in GitHub Desktop.
Convert file text encoding
This file contains 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
# When you receive "warning: null character(s) ignore", there is a null byte hidden number in the source code. | |
# This is likely the result of creating a file in Visual Studio which defaults to UTF-16LE and trying to read | |
# it back as UTF8. | |
# To check text encoding of the file, run the following and retrieve the `charset` | |
file -I [FILE] | |
# To convert the file to UTF8 (or any other encoding) | |
iconv -f [CURRENT_ENCODING] -t UTF8 [FILE] > temp | |
mv temp [FILE] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
also,
dos2unix