diff --git a/init.el b/init.el index a640d69..4380150 100644 --- a/init.el +++ b/init.el @@ -487,6 +487,18 @@ _h_ _l_ _o_k _y_ank (test eq window-system 'x)) (cdr (assoc "application" mailcap-mime-data)))))) +(use-package pp + :commands (db/eval-last-sexp-or-region + pp-eval-expression) + :config (progn + (defun db/eval-last-sexp-or-region (prefix) + ;; http://pages.sachachua.com/.emacs.d/Sacha.html#orgheadline140 + "Eval region from BEG to END if active, otherwise the last sexp." + (interactive "P") + (if (and (mark) (use-region-p)) + (eval-region (min (point) (mark)) (max (point) (mark))) + (pp-eval-last-sexp prefix))))) + (use-package quail :defer t :config (progn @@ -1257,18 +1269,6 @@ _h_ _l_ _o_k _y_ank :commands (page-break-lines-mode) :diminish page-break-lines-mode) -(use-package pp - :commands (db/eval-last-sexp-or-region - pp-eval-expression) - :config (progn - (defun db/eval-last-sexp-or-region (prefix) - ;; http://pages.sachachua.com/.emacs.d/Sacha.html#orgheadline140 - "Eval region from BEG to END if active, otherwise the last sexp." - (interactive "P") - (if (and (mark) (use-region-p)) - (eval-region (min (point) (mark)) (max (point) (mark))) - (pp-eval-last-sexp prefix))))) - (use-package python :defer t :config (progn