summaryrefslogtreecommitdiff
path: root/jakob.org
diff options
context:
space:
mode:
authorJakob L. Kreuze2019-02-03 18:14:43 -0500
committerJakob L. Kreuze2019-02-03 18:21:27 -0500
commit703f2c9a60773989a8e434d00b2e32a8cd9afcbd (patch)
tree6d6c12bad03862ce8f8dcb16fb0df8d2ef091aac /jakob.org
parentabe98bf7c4ce8214f61c28236706d7bb424ac1b1 (diff)
Add configuration for cc-mode
Diffstat (limited to 'jakob.org')
-rw-r--r--jakob.org17
1 files changed, 17 insertions, 0 deletions
diff --git a/jakob.org b/jakob.org
index 72048db..67a399a 100644
--- a/jakob.org
+++ b/jakob.org
@@ -1670,3 +1670,20 @@ code, keybindings, symbol properties, and more.
("C-h C" . helpful-command)
("C-c C-d" . helpful-at-point)))
#+END_SRC
+* cc
+
+Generally, I adhere to the [[https://www.kernel.org/doc/html/v4.10/process/coding-style.html][Linux kernel coding style]].
+
+#+BEGIN_SRC elisp
+(use-package cc-mode
+ :hook
+ (c-mode . (lambda () (c-set-style "linux")))
+#+END_SRC
+
+Automatically insert the leading asterisk when continuing a multi-line comment.
+
+#+BEGIN_SRC elisp
+ :bind
+ (:map c-mode-map
+ ("RET" . c-indent-new-comment-line)))
+#+END_SRC

© 2015 - 2026 Jakob L. Kreuze