What Is The Appropriate Character Encoding For A Git Repo?
Specifically what encoding to use if the repo has both code and docs? Any .md or .htm files are saved as UTF-8, but code is cp1252 (my compiler doesn't like the 3-byte BOM which Windows adds to UTF-8 files).
As seen in Git GUI tool (Edit -> Options...):
Frankly, does it even matter what setting I choose?
My system is Windows 8.1, and the system encoding is
The setting in git GUI only sets the default encoding. Real encoding should be set via .gitattributes. For example:
echo '*.html encoding=utf-8' >> .gitattributes echo '*.c encoding=cp1252' >> .gitattributes
PS. What editor do you use that you cannot configure BOM in it? I recommend to disable BOM and use one encoding for all text files.
- → Authenticate with a cookie using laravel 5.1 and jwt
- → Finding a specific GitLab tag from PHP
- → React: How to publish page on server using React-starter-kit
- → babel-loader, webpack, ES2015 modules: "Element type is invalid"
- → Create a function-attribute of a function, which is, in its turn, a method of an object literal
- → Model Validation in laravel 5.1 not working
- → GIT fatal: loose object
- → Laravel validation required rule not working
- → Axios array map callback
- → Where does this `webpack://` come from for `webpack-dev-middleware`?
- → error when trying to modify project in laravel forge
- → GitHub Pages and Jekyll content duplication and SEO issues
- → Use Laravel repositories with Datatables