Summary
The project has no .editorconfig file. While ezc/.clang-format handles C formatting, there is no editor-agnostic config for basic settings like indent style, trailing whitespace, and final newlines. An .editorconfig ensures contributors using any editor (VS Code, Vim, Emacs, JetBrains, etc.) get consistent defaults.
Implementation guidance
- Inspect existing code to determine current conventions:
- C files (
ezc/src/): check indent style (spaces vs tabs) and width
- Go files (
cmd/ez/, internal/, pkg/): tabs per Go standard
- Makefiles: tabs (required by make)
- YAML (
.github/workflows/): 2-space indent
- Shell scripts (
scripts/): check current style
- Create a root
.editorconfig capturing these conventions
- Standard settings to include:
indent_style, indent_size, end_of_line, charset, trim_trailing_whitespace, insert_final_newline
Example
root = true
[*]
charset = utf-8
end_of_line = lf
trim_trailing_whitespace = true
insert_final_newline = true
[*.c]
indent_style = space
indent_size = 4
[*.h]
indent_style = space
indent_size = 4
[*.go]
indent_style = tab
[Makefile]
indent_style = tab
[*.yml]
indent_style = space
indent_size = 2
[*.sh]
indent_style = space
indent_size = 2
Files to create
Summary
The project has no
.editorconfigfile. Whileezc/.clang-formathandles C formatting, there is no editor-agnostic config for basic settings like indent style, trailing whitespace, and final newlines. An.editorconfigensures contributors using any editor (VS Code, Vim, Emacs, JetBrains, etc.) get consistent defaults.Implementation guidance
ezc/src/): check indent style (spaces vs tabs) and widthcmd/ez/,internal/,pkg/): tabs per Go standard.github/workflows/): 2-space indentscripts/): check current style.editorconfigcapturing these conventionsindent_style,indent_size,end_of_line,charset,trim_trailing_whitespace,insert_final_newlineExample
Files to create
.editorconfig