feat: ask before quickloading a session
This commit is contained in:
parent
c8070f11a4
commit
09504ef9fe
1 changed files with 11 additions and 6 deletions
|
@ -67,12 +67,17 @@
|
||||||
;;; Commands
|
;;; Commands
|
||||||
|
|
||||||
;;;###autoload
|
;;;###autoload
|
||||||
(defun doom/quickload-session ()
|
(defun doom/quickload-session (force)
|
||||||
"TODO"
|
"Load the last session saved.
|
||||||
(interactive)
|
If the FORCE \\[universal-argument] is provided
|
||||||
(message "Restoring session...")
|
then no confirmation is asked."
|
||||||
(doom-load-session)
|
(interactive "P")
|
||||||
(message "Session restored. Welcome back."))
|
(if (or force
|
||||||
|
(yes-or-no-p "This will wipe your current session, do you want to continue? "))
|
||||||
|
(progn (message "Restoring session...")
|
||||||
|
(doom-load-session)
|
||||||
|
(message "Session restored. Welcome back."))
|
||||||
|
(message "Session not restored.")))
|
||||||
|
|
||||||
;;;###autoload
|
;;;###autoload
|
||||||
(defun doom/quicksave-session ()
|
(defun doom/quicksave-session ()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue