File tree 1 file changed +20
-5
lines changed
1 file changed +20
-5
lines changed Original file line number Diff line number Diff line change @@ -63,6 +63,21 @@ hit `<tab>`.
63
63
64
64
* Use ** spaces** for indentation. No hard tabs.
65
65
66
+ In practical terms this means you should add the following to your
67
+ Emacs config:
68
+
69
+ ``` el
70
+ (setq indent-tabs-mode nil)
71
+ ```
72
+
73
+ An even better idea would be to force the use of spaces using
74
+ ` .dir-locals.el ` in each of your Emacs Lisp projects.
75
+
76
+ ``` el
77
+ ((emacs-lisp-mode
78
+ (indent-tabs-mode nil)))
79
+ ```
80
+
66
81
* For regular functions, vertically align function arguments.
67
82
68
83
``` el
@@ -81,13 +96,13 @@ hit `<tab>`.
81
96
82
97
```el
83
98
;; good
84
- (format
99
+ (format
85
100
"%s %d"
86
101
something
87
102
something-else)
88
103
89
104
;; bad
90
- (format
105
+ (format
91
106
"%s %d"
92
107
something
93
108
something-else)
@@ -108,9 +123,9 @@ hit `<tab>`.
108
123
;; bad - four spaces on the body
109
124
(when something
110
125
(something-else))
111
-
126
+
112
127
;; bad - aligned like a regular function
113
- (when
128
+ (when
114
129
something
115
130
(something-else))
116
131
```
@@ -432,7 +447,7 @@ name clashes.
432
447
(global-set-key (kbd "C-l C-l") #'redraw-display)
433
448
(cl-labels ((butterfly () (message "42")))
434
449
(funcall #'butterfly))
435
-
450
+
436
451
;; bad
437
452
(cl-remove-if-not 'evenp numbers)
438
453
(global-set-key (kbd "C-l C-l") 'redraw-display)
You can’t perform that action at this time.
0 commit comments