110 lines
1.9 KiB
INI
110 lines
1.9 KiB
INI
# EditorConfig Specification: https://EditorConfig.org
|
|
root = true
|
|
|
|
# Universal Defaults
|
|
[*]
|
|
charset = utf-8
|
|
end_of_line = lf
|
|
indent_size = 2
|
|
indent_style = space
|
|
insert_final_newline = true
|
|
trim_trailing_whitespace = true
|
|
|
|
# Markdown & Documentation
|
|
[*.md]
|
|
trim_trailing_whitespace = false
|
|
|
|
# Ansible & YAML Configuration
|
|
[*.{yml,yaml}]
|
|
indent_size = 2
|
|
indent_style = space
|
|
|
|
# Infrastructure as Code (OpenTofu / Terraform)
|
|
[*.{tf,tfvars,tofu}]
|
|
indent_size = 2
|
|
indent_style = space
|
|
|
|
# JSON Data Files
|
|
[*.json]
|
|
indent_size = 2
|
|
indent_style = space
|
|
|
|
# Rust (Rust standard mandates 4 spaces)
|
|
[*.rs]
|
|
indent_size = 4
|
|
indent_style = space
|
|
|
|
# Python
|
|
[*.py]
|
|
indent_size = 4
|
|
indent_style = space
|
|
|
|
# Perl
|
|
[*.{pl,pm,t,pod}]
|
|
indent_size = 4
|
|
indent_style = space
|
|
|
|
# Systems Programming (C, C++, Headers, eBPF)
|
|
[*.{c,cc,cpp,cxx,h,hh,hpp,hxx,bpf.c,bpf.h}]
|
|
indent_size = 4
|
|
indent_style = space
|
|
|
|
# Low-Level Assembly (x86_64, aarch64, riscv, Linker Scripts)
|
|
[*.{s,S,asm,ld,lds}]
|
|
indent_style = tab
|
|
indent_size = 8
|
|
|
|
# Device Tree (Linux Kernel Hardware Trees)
|
|
[*.{dts,dtsi}]
|
|
indent_style = tab
|
|
indent_size = 8
|
|
|
|
# Parser & Lexer Grammars (Bison / Flex / Yacc)
|
|
[*.{y,l,yy,ll}]
|
|
indent_style = tab
|
|
indent_size = 8
|
|
|
|
# Linux Kernel Kconfig / Kbuild
|
|
[{Kconfig*,Kbuild*,*.kconfig}]
|
|
indent_style = tab
|
|
indent_size = 8
|
|
|
|
# Makefiles & Build Systems (Hard tabs mandated by spec)
|
|
[{Makefile*,*.mk}]
|
|
indent_style = tab
|
|
|
|
# AWK & Sed Scripts
|
|
[*.{awk,sed}]
|
|
indent_size = 4
|
|
indent_style = space
|
|
|
|
# Java
|
|
[*.java]
|
|
indent_size = 4
|
|
indent_style = space
|
|
|
|
# Go (Golang standard enforces hardware tabs)
|
|
[*.go]
|
|
indent_style = tab
|
|
indent_size = 4
|
|
|
|
# PHP
|
|
[*.php]
|
|
indent_size = 4
|
|
indent_style = space
|
|
|
|
# UNIX / POSIX Shells (Bash, Sh, Ksh, Csh, Tcsh, Zsh)
|
|
[*.{sh,bash,ksh,csh,tcsh,zsh}]
|
|
indent_size = 2
|
|
indent_style = space
|
|
|
|
# Windows PowerShell & Batch Scripts
|
|
[*.{ps1,psm1,psd1}]
|
|
indent_size = 4
|
|
indent_style = space
|
|
|
|
[*.{bat,cmd}]
|
|
end_of_line = crlf
|
|
indent_size = 2
|
|
indent_style = space
|