From 61e4c78dd6ca9567dd43c81ed3a74f30a405d4cc Mon Sep 17 00:00:00 2001 From: syl20bnr Date: Sun, 8 Mar 2015 00:18:29 -0500 Subject: [PATCH] Add dynamic information to the paste micro-state --- spacemacs/packages.el | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/spacemacs/packages.el b/spacemacs/packages.el index 2805f3016..6d7169d27 100644 --- a/spacemacs/packages.el +++ b/spacemacs/packages.el @@ -679,10 +679,14 @@ which require an initialization must be listed explicitly in the list.") (defadvice evil-visual-paste (after spacemacs/evil-visual-paste activate) "Initate the paste micro-state after the execution of evil-visual-paste" (spacemacs/paste-micro-state)) + (defun spacemacs//paste-ms-doc () + "The documentation for the paste micro-state." + (format (concat "[%s/%s] Type [p] or [P] to paste the previous or " + "next copied text, [C-p] or [C-P] to paste the same " + "text before of after the point.") + (length kill-ring-yank-pointer) (length kill-ring))) (spacemacs|define-micro-state paste - :doc (concat "Type [p] or [P] to paste the previous or " - "next copied text, [C-p] or [C-P] to paste the same text " - "before of after the point.") + :doc (spacemacs//paste-ms-doc) :use-minibuffer t :bindings ("p" evil-paste-pop)