diff --git a/.config/next/init.lisp b/.config/next/init.lisp index 7010f69c..4277e513 100644 --- a/.config/next/init.lisp +++ b/.config/next/init.lisp @@ -14,11 +14,14 @@ (defun eval-in-emacs (&rest s-exps) "Evaluate S-EXPS with emacsclient." - (uiop:run-program - (list "emacsclient" "--eval" - ;; Discard the package prefix. - (ppcre:regex-replace-all - "next::" (prin1-to-string `(progn ,@s-exps)) "")))) + (let ((s-exps-string (cl-strings:replace-all + (write-to-string + `(progn ,@s-exps) :case :downcase) + ;; Discard the package prefix. + "next::" ""))) + (format *error-output* "Sending to Emacs:~%~a~%" s-exps-string) + (uiop:run-program + (list "emacsclient" "--eval" s-exps-string)))) (define-command org-capture () "Org-capture current page."