"We’ve detected the file encoding as ISO-8859-1. When you commit changes we will transcode it to UTF-8"
This is what GitHub displays when I try to upload Windows 1252 .txt files.
Result: All characters unkonwn by UTF-8 are displayed as �
My ATOM editor is using Windows 1252 as default successfully but the staged changes window is showing the �'s.
How can I stop GitHub from doing this?
In addition of setting a
.gitattributes
encoding directive to utf-8, you can also convert your existing files to utf-8, as in here:You can tweak the script to limit that to only a subset of your files.
Only by pushing utf-8 files will you be sure to see the right characters in your GitHub repo repo page.