>From a47b2cb213af71978e8a16d596934fa318847971 Mon Sep 17 00:00:00 2001 From: Stefan Kangas Date: Thu, 16 Jan 2020 01:07:20 +0100 Subject: [PATCH 1/3] Obsolete viper-load-hook in favor of eval-after-load * lisp/emulation/viper-init.el (viper-load-hook): Make obsolete. * doc/misc/viper.texi (Rudimentary Changes): Doc fix - no longer mention viper-load-hook. --- doc/misc/viper.texi | 5 +---- lisp/emulation/viper-init.el | 3 +++ 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/misc/viper.texi b/doc/misc/viper.texi index 9ce809e7d4..087eb2701d 100644 --- a/doc/misc/viper.texi +++ b/doc/misc/viper.texi @@ -1755,7 +1755,7 @@ Rudimentary Changes Insert state, or Emacs state. This heuristics works well in virtually all cases. @code{nil} means you either has to invoke @code{viper-mode} manually for each buffer (or you can add @code{viper-mode} to the appropriate major mode -hooks using @code{viper-load-hook}). +hooks). This option must be set in your Viper customization file. @item viper-custom-file-name "~/.emacs.d/viper" @@ -1903,9 +1903,6 @@ Rudimentary Changes @item viper-emacs-state-hook nil List of (parameterless) functions called just after switching from Vi state to Emacs state. -@item viper-load-hook nil -List of (parameterless) functions called just after loading Viper. This is -the last chance to do customization before Viper is up and running. @end table @noindent You can reset some of these constants in Viper with the Ex command @kbd{:set} diff --git a/lisp/emulation/viper-init.el b/lisp/emulation/viper-init.el index 511c68f24a..09fa0ba7f6 100644 --- a/lisp/emulation/viper-init.el +++ b/lisp/emulation/viper-init.el @@ -923,6 +923,9 @@ viper-load-hook :type 'hook :group 'viper-hooks) +(make-obsolete-variable 'viper-load-hook + "use `with-eval-after-load' instead." "28.1") + (defun viper-restore-cursor-type () (condition-case nil (setq cursor-type (default-value 'cursor-type)) -- 2.20.1