Skip to content

Commit b18fcf7

Browse files
authored
README.md: Misc updates (#388)
First and foremost, try and explain that EditorConfig is bundled with Emacs and that it's both "the same yet different". Also, mention that ideally major modes should be changed instead of adding stuff to `editorconfig-indentation-alist`.
1 parent 1e9931d commit b18fcf7

1 file changed

Lines changed: 18 additions & 1 deletion

File tree

README.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,18 @@ This is an [EditorConfig][] plugin for [Emacs][].
99

1010
## Getting Started
1111

12+
If you're using Emacs≥30, then support for EditorConfig is bundled
13+
directly with Emacs and all you need to do is:
14+
15+
```emacs-lisp
16+
(editorconfig-mode 1)
17+
```
18+
19+
The code that comes with Emacs derives from the code in this separate
20+
package but has a few differences, mostly because it uses hooks that are new
21+
in Emacs-30. In most cases it behaves in the same way, and the two codes
22+
are (still) in the process of being synchronized.
23+
1224
### package.el
1325

1426
This package is available from [MELPA][], [MELPA Stable][] and [NonGNU ELPA][].
@@ -141,7 +153,12 @@ sorry to say, it cannot be perfect. Especially it is difficult to support
141153
brand-new major-modes.
142154
Please feel free to submit issue or pull-request for such major-mode!
143155

144-
Supported major-modes and their indentation configs are defined in the variable
156+
In most cases it is better to modify the major mode itself
157+
either to use a "standard" indentation size variable name
158+
like `<MODE>-indent-offset` or to set `editorconfig-indent-size-vars`.
159+
160+
Those major modes which cannot yet follow this convention need to have
161+
their indentation configs defined in the variable
145162
`editorconfig-indentation-alist`.
146163

147164
### Not work at all for FOO-mode!

0 commit comments

Comments
 (0)