From dafceb12e8e2fd71e48703b4ba152a6db35bcfd3 Mon Sep 17 00:00:00 2001 From: syl20bnr Date: Thu, 11 Dec 2014 22:24:18 -0500 Subject: [PATCH] Fixes #238 Smartparens-strict-mode not working Previous commits was about Python, this commit should fix it for all the other modes. --- spacemacs/packages.el | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/spacemacs/packages.el b/spacemacs/packages.el index f2ac1afa9..e23fa3c1c 100644 --- a/spacemacs/packages.el +++ b/spacemacs/packages.el @@ -640,7 +640,14 @@ determine the state to enable when escaping from the insert state.") (define-and-bind-text-object "|" "|" "|") ;; between percent signs: (define-and-bind-text-object "%" "%" "%") - ))) + + ;; support smart 1parens-strict-mode + (if (ht-contains? config-system-all-packages 'smartparens) + (defadvice evil-delete-backward-char-and-join + (around spacemacs/evil-delete-backward-char-and-join activate) + (if smartparens-strict-mode + (call-interactively 'sp-backward-delete-char) + ad-do-it)))))) (defun spacemacs/init-evil-args () (use-package evil-args