From 44a8d0139d0fe3ea241e404ffcafdf749daef9ef Mon Sep 17 00:00:00 2001 From: Tom Willemse Date: Thu, 17 Dec 2015 01:27:39 +0100 Subject: [PATCH] Move locally-enable-double-spaces to editing lib --- emacs/.emacs.d/init.el | 6 +----- emacs/.emacs.d/site-lisp/oni-editing.el | 5 +++++ 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el index 5900ee8..9446e03 100644 --- a/emacs/.emacs.d/init.el +++ b/emacs/.emacs.d/init.el @@ -141,10 +141,6 @@ MODE1 is enabled and vice-versa." "Set the `disabled' property for each item in FUNCTIONS to nil." (mapc #'(lambda (f) (put f 'disabled nil)) functions)) -(defun oni:locally-enable-double-spaces () - "Specify that two spaces end a sentence in the current buffer." - (setq-local sentence-end-double-space t)) - (defun oni:lua-mode-func() "Function for `lua-mode-hook'." (local-unset-key (kbd ")")) @@ -1012,7 +1008,7 @@ If no direction is given, don't split." ac-source-functions ac-source-variables ac-source-symbols))) - #'oni:locally-enable-double-spaces #'oni:set-emacs-lisp-symbols + 'oni:locally-enable-double-spaces #'oni:set-emacs-lisp-symbols #'paredit-mode #'eldoc-mode #'oni:set-emacs-lisp-keys) (oni:add-hooks 'eshell-mode-hook diff --git a/emacs/.emacs.d/site-lisp/oni-editing.el b/emacs/.emacs.d/site-lisp/oni-editing.el index 97ca1f2..315750d 100644 --- a/emacs/.emacs.d/site-lisp/oni-editing.el +++ b/emacs/.emacs.d/site-lisp/oni-editing.el @@ -65,6 +65,11 @@ (mark-defun) (indent-region (region-beginning) (region-end)))) +;;;###autoload +(defun oni:locally-enable-double-spaces () + "Specify that two spaces end a sentence in the current buffer." + (setq-local sentence-end-double-space t)) + ;;;###autoload (defun oni:upcase-prev (num) (interactive "p")