Skip to content

Commit

Permalink
make EvalSexp work in non-lisp buffer
Browse files Browse the repository at this point in the history
Sometimes I want to just evaluate the sexp from an Org Mode buffer (or
any buffer really)
  • Loading branch information
ag91 committed Oct 27, 2024
1 parent 654ccc5 commit 239ae4c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions molds/core.el
Original file line number Diff line number Diff line change
Expand Up @@ -363,8 +363,7 @@ This is a more focused view than `CodeToTree.'")

(me-register-mold
:key "EvalSexp"
:given (:fn (or (eq major-mode 'emacs-lisp-mode)
(eq major-mode 'lisp-interaction-mode)))
:given (:fn (thing-at-point 'sexp))
:then (:fn
(let* ((orig-point (point))
(tree (progn (unless (or (me-get-region) (list-at-point))
Expand Down

0 comments on commit 239ae4c

Please sign in to comment.