Skip to content

Commit

Permalink
Restores .editorconfig file.
Browse files Browse the repository at this point in the history
  • Loading branch information
c4milo committed Sep 12, 2015
1 parent 87433de commit 2c89ea3
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
root = true

; Unix-style newlines with a newline ending every file
[*]
end_of_line = lf
insert_final_newline = true
charset = utf-8

; Golang
[*.go]
indent_style = tab
indent_size = 4
trim_trailing_whitespace = true
insert_final_newline = true

; YAML
[*.yaml]
indent_style = space
indent_size = 2
trim_trailing_whitespace = true
insert_final_newline = true

2 comments on commit 2c89ea3

@sanbornm
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why have this? Shouldn't these settings live in the editor? What if every different editor put a file in the repo like this? It doesn't scale well.

For Go I think "go fmt" takes care of this. YAML will probably not be used much in this repo

@c4milo
Copy link
Member Author

@c4milo c4milo commented on 2c89ea3 Sep 14, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was there just in case, editors don't add this file, they read from it if the editor has the editorconfig plugin. However, you are right, go fmt should take care of the Go code. The only YAML file so far is the Travis configuration.

Please sign in to comment.