aboutsummaryrefslogtreecommitdiff
path: root/Doom/.doom.d/org/personal.org
diff options
context:
space:
mode:
Diffstat (limited to 'Doom/.doom.d/org/personal.org')
-rw-r--r--Doom/.doom.d/org/personal.org12
1 files changed, 12 insertions, 0 deletions
diff --git a/Doom/.doom.d/org/personal.org b/Doom/.doom.d/org/personal.org
index 37a532a..f21bbce 100644
--- a/Doom/.doom.d/org/personal.org
+++ b/Doom/.doom.d/org/personal.org
@@ -71,3 +71,15 @@ Function to quickly check weather, which is what I wanted wttrin for.
(interactive)
(wttrin (dx:password-store/get-password "location")))
#+END_SRC
+* Newline
+Insert a newline without having to exit normal mode!
+#+BEGIN_SRC elisp
+(defun dx:newline (&optional BACKWARD)
+ (interactive)
+ (message "%s" BACKWARD)
+ (let ((old (point)))
+ (cond ((and BACKWARD (= BACKWARD 1)) (+default/newline-above))
+ (t (+default/newline-below)))
+ (goto-char (+ old 1))
+ (evil-normal-state)))
+#+END_SRC