News for hackers. Stuff that matters.
Re:EditorConfig by teamhappy on Monday November 09, 2015 @08:30AM (#10532875)

    > Crucially, what about new files?
vim-sleuth handles this one by looking at similar files in the same directory (or the rest of the tree, if it doesn't find any.)

    > For charset, [...]
Almost all code bases use UTF-8 without BOM, which also happens to be the default encoding in most editors.

    > Same goes for new line at the end of the file, 
    > how do you know ALL files of this type are meant
    > to end with a new line [...] ?
POSIX wants the newline.

I get your point though. I used to use editorconfig myself, but it didn't really do anything for me. IMHO linters/formatters do a much better job.

Re:EditorConfig by beaker52 on Monday November 09, 2015 @08:43AM (#10532934)
That's cool, but that's one plugin for one editor - editorconfig is a simple plugin with a very wide range of support to solve the problem it solves.

Linters and formatters are great for enforcing code styles but they tend to be per language and require more configuration, shy of ripping off an existing spec.

If you don't want to go the whole hog and only need some basic constraints then editorconfig is easy to throw into a repo root.

Re:EditorConfig by 1wd on Monday November 09, 2015 @12:34PM (#10534414)
Notepad++ defaults to Ansi (although it can be changed). Visual Studio defaults to UTF-8 with BOM. (And I don't think you can change that easily.)
Re:EditorConfig by deathanatos on Tuesday November 10, 2015 @04:40PM (#10542740)
"ANSI" hardly counts as a default. (ANSI is MS's incorrect term to mean the system's encoding, which can be any of a number of different character sets.)