The EditorConfig ProjectThe EditorConfig project defines a simple file format for configuring common text-editor options such as indentation sizes. These configuration files are designed to sit alongside a project's source code, allowing text editors to use the right options on a file-by-file basis. The EditorConfig project provides plugins for many common text editors, making the format fully cross-platform. File FormatHere is an example configuration file: ; Top-most EditorConfig fileroot = true; Unix-style newlines[*]end_of_line = LF; 4-column space indentation[*.cs]indent_style = spaceindent_size = 4; 2-column tab indentation[*.js]indent_style = tabindent_size = 2 To load the settings for a particular source file, the plugin searches for a file named ".editorconfig" in the same directory as the source file and in each parent directory. The plugin applies all the properties that match the current filename, exactly as if they had been set by hand in the "Tools / Options..." dialog box. For more information, see the project's web site at EditorConfig.org. The source code is available on GitHub. |