Skip to content

Commit

Permalink
ts: remove explicit call to enter insert state in insertion commands
Browse files Browse the repository at this point in the history
(This is now part of the `symex-define-insertion-command` macro)
  • Loading branch information
countvajhula committed Feb 19, 2025
1 parent edb604c commit 0d94e0c
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions symex-transformations-ts.el
Original file line number Diff line number Diff line change
Expand Up @@ -147,15 +147,13 @@ If the deletion results in an empty line it will be removed."
"Insert at beginning of symex."
(interactive)
(when (symex-ts-get-current-node)
(goto-char (symex-ts--node-start-position (symex-ts-get-current-node)))
(evil-insert-state)))
(goto-char (symex-ts--node-start-position (symex-ts-get-current-node)))))

(defun symex-ts-insert-at-end ()
"Insert at end of symex."
(interactive)
(when (symex-ts-get-current-node)
(goto-char (symex-ts--node-end-position (symex-ts-get-current-node)))
(evil-insert-state)))
(goto-char (symex-ts--node-end-position (symex-ts-get-current-node)))))

(defun symex-ts-insert-before ()
"Insert before symex (instead of vim's default at the start of line)."
Expand All @@ -179,8 +177,7 @@ alias for inserting at the end."
(interactive)
(when (symex-ts-get-current-node)
(goto-char (symex-ts--node-end-position (symex-ts-get-current-node)))
(newline-and-indent)
(evil-insert-state)))
(newline-and-indent)))

(defun symex-ts-open-line-before ()
"Open new line before symex."
Expand Down

0 comments on commit 0d94e0c

Please sign in to comment.