From 97709bc6545ff4d8cce9cf04aaf627f8d05a6509 Mon Sep 17 00:00:00 2001 From: Kyle Sexton <153232337+kyle-sexton@users.noreply.github.com> Date: Tue, 23 Jun 2026 18:11:55 -0400 Subject: [PATCH] feat(editorconfig): add gitconfig tab-indentation section Git writes and idiomatically uses tab indentation under each section, so the space default is wrong for git config files. Add a section covering the plain file, gitconfig includes, and chezmoi-style source forms (dot_gitconfig, dot_gitconfig.tmpl) so a consumer tracking a gitconfig passes editorconfig-checker without a local override. Surfaced by the kyle-sexton/dotfiles adoption, which can now drop its consumer-local gitconfig section. Co-Authored-By: Claude Opus 4.8 (1M context) --- .editorconfig | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.editorconfig b/.editorconfig index 422f96ad..19951d42 100644 --- a/.editorconfig +++ b/.editorconfig @@ -46,6 +46,12 @@ indent_size = 4 [*.{cmd,bat}] end_of_line = crlf +# Git config — git writes (and idiomatically uses) tab indentation under each +# section, so the space default does not apply. Covers the plain file, gitconfig +# includes, and chezmoi-style source forms (dot_gitconfig, dot_gitconfig.tmpl). +[{.gitconfig,*.gitconfig,dot_gitconfig*}] +indent_style = tab + # Lockfiles — generated; suppress formatting enforcement. [{package-lock.json,*.lock}] indent_size = unset