Reputation: 4616
I have uploaded a repository from Mac to git server where repository was having html files with Asian characters, now when I am cloning the same repository in Windows7, the html files are showing corrupt data, while I can see on the gitweb that files on git server are good one. Any idea, what I am doing wrong and how to fix it?
Following is my git config
[core]
repositoryformatversion = 0
filemode = false
bare = false
logallrefupdates = true
symlinks = false
ignorecase = true
hideDotFiles = dotGitOnly
autocrlf = false
quotepath = off
[alias]
st = status
[i18n]
logoutputencoding = utf8
commitencoding = utf8
Upvotes: 1
Views: 1216
Reputation: 55573
"Server-side" Git is not interested in the contents of your files -- it does not even know they exist as it operates on opaque blobs of data which clients send it.
Moreover "client-side" Git does not touch your files either unless clean/smudge filters are in place and/or EOL-conversion is enabled (which has nothing to do with encodings anyway so does not apply).
Hence I'm with @joahim-sauer on this matter — supposedly your problem is in interpretation. Note that Windows Notepad looks at BOMs to know files are UTF-8, and you won't convince it a file is UTF-8 unless the file contains BOM, and many files doesn't (and many people think they shouldn't, ever).
Upvotes: 3