(github.com) dotfiles/.config/emacs at master · andreyorst/dotfiles
ROAM_REFS: https://github.com/andreyorst/dotfiles/tree/master/.config/emacs#smartparens
(github.com) dotfiles/.config/emacs/init.el at 6849f27cea5d2dfa0222b74dd3414b16a028ddde · andreyorst/dotfiles website
ROAM_REFS: https://github.com/andreyorst/dotfiles/blob/6849f27cea5d2dfa0222b74dd3414b16a028ddde/.config/emacs/init.el
Snippet of interest relating to Smartparens configuration:
(use-package smartparens
:hook (((clojure-mode
emacs-lisp-mode
common-lisp-mode
scheme-mode
lisp-mode
racket-mode
fennel-mode
cider-repl-mode
racket-repl-mode
geiser-repl-mode
inferior-lisp-mode
inferior-emacs-lisp-mode
sly-mrepl-mode)
. smartparens-strict-mode)
((eval-expression-minibuffer-setup
lisp-data-mode)
. aorst/minibuffer-enable-sp)
(prog-mode . smartparens-mode))
:bind (:map smartparens-mode-map
("C-M-q" . sp-indent-defun)
:map smartparens-strict-mode-map
(";" . sp-comment))
:custom
(sp-highlight-pair-overlay nil)
(sp-highlight-wrap-overlay nil)
(sp-highlight-wrap-tag-overlay nil)
(sp-show-pair-delay 0)
(sp-echo-match-when-invisible nil)
:config
(require 'smartparens-config)
(sp-use-paredit-bindings)
(define-key smartparens-mode-map (kbd "M-r") 'sp-rewrap-sexp) ; needs to be set manually, because :bind section runs before config
(add-to-list 'sp-lisp-modes 'fennel-mode t)
(defun aorst/minibuffer-enable-sp ()
"Enable `smartparens-strict-mode' in the minibuffer, during `eval-expression'."
(setq-local comment-start ";")
(sp-local-pair 'minibuffer-pairs "'" nil :actions nil)
(sp-local-pair 'minibuffer-pairs "`" nil :actions nil)
(sp-update-local-pairs 'minibuffer-pairs)
(smartparens-strict-mode 1)))
(github.com) dotfiles/.config/emacs/early-init.el at master · andreyorst/dotfiles website
ROAM_REFS: https://github.com/andreyorst/dotfiles/blob/master/.config/emacs/early-init.el
Relevant snippet for silencing Emacs native compilation warnings:
(when (featurep 'native-compile)
(defvar native-comp-async-report-warnings-errors)
(setq native-comp-async-report-warnings-errors 'silent))