From 461ba3f977a580e1c3f136c677e7ec6253f2775b Mon Sep 17 00:00:00 2001 From: Aryadev Chavali Date: Thu, 13 Jan 2022 04:57:37 +0000 Subject: (Emacs)+nice features that work with vim motions --- Emacs/.config/emacs/config.org | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'Emacs/.config/emacs') diff --git a/Emacs/.config/emacs/config.org b/Emacs/.config/emacs/config.org index 2b38008..2f45cb2 100644 --- a/Emacs/.config/emacs/config.org +++ b/Emacs/.config/emacs/config.org @@ -2307,6 +2307,10 @@ opposing style. :hook (c-mode-hook . auto-fill-mode) (c++-mode-hook . auto-fill-mode) + :general + (:states '(normal motion visual) + "(" #'c-beginning-of-statement + ")" #'c-end-of-statement) :pretty (c-mode-hook ("puts" . "φ") @@ -2339,6 +2343,7 @@ opposing style. ("return" . "⟼")) :init (setq-default c-basic-offset 2) + (setq-default c-auto-newline t) (setq-default c-default-style '((other . "user"))) (with-eval-after-load "autoinsert" @@ -2627,6 +2632,11 @@ appropriately. ("for" . "∀") ("mapc" . "∀") ("mapcar" . "∀")) + :general + (:states '(normal motion visual) + :keymaps '(emacs-lisp-mode-map lisp-mode-map) + ")" #'sp-next-sexp + "(" #'sp-previous-sexp) :config (defun +dx/lisp-indent-function (indent-point state) (let ((normal-indent (current-column)) -- cgit v1.2.3-13-gbd6f