diff options
author | jao <jao@gnu.org> | 2024-11-12 18:58:14 +0000 |
---|---|---|
committer | jao <jao@gnu.org> | 2024-11-12 18:58:14 +0000 |
commit | 418212e4eb963813c078cf290cddfe7e3defd7ed (patch) | |
tree | 3c265c395b0afe67f88f5e18a34f368a88f970d6 /init.el | |
parent | 8ddc2d688cd37693320e46aa3d35d72f06e5bab3 (diff) | |
download | elibs-418212e4eb963813c078cf290cddfe7e3defd7ed.tar.gz elibs-418212e4eb963813c078cf290cddfe7e3defd7ed.tar.bz2 |
Revert "{if,when}-let deprecation in emacs 31"main
This reverts commit 4308710de811e3b4e2fb47f9024439df03e96b90.
Diffstat (limited to 'init.el')
-rw-r--r-- | init.el | 20 |
1 files changed, 10 insertions, 10 deletions
@@ -411,7 +411,7 @@ "Toggle eldoc's documentation buffer." (interactive) (let ((buffer (eldoc-doc-buffer))) - (if-let* ((w (and buffer (get-buffer-window buffer)))) + (if-let (w (and buffer (get-buffer-window buffer))) (delete-window w) (eldoc-doc-buffer t)))) @@ -641,7 +641,7 @@ (jao-shell-string "curl -s" "https://wttr.in/?format=%l++%m++%C+%c+%t+%w++%p")) (jao-afio-goto-scratch) - (if-let* ((b (get-buffer "*wttr*"))) + (if-let ((b (get-buffer "*wttr*"))) (progn (pop-to-buffer b) (term-send-string (get-buffer-process nil) "clear;curl wttr.in\n")) (jao-exec-in-term "curl wttr.in" "*wttr*")))) @@ -1487,9 +1487,9 @@ (defun jao-open-doc (&optional file page height) (interactive) - (when-let* ((file (or file - (read-file-name "Document: " - (concat jao-org-dir "/doc/"))))) + (when-let (file (or file + (read-file-name "Document: " + (concat jao-org-dir "/doc/")))) (funcall jao-open-doc-fun file page height))) (defun jao-select-pdf () @@ -1499,7 +1499,7 @@ (defun jao-open-with-zathura () (interactive) - (when-let* ((f buffer-file-name)) + (when-let (f buffer-file-name) (let ((p (jao-doc-view-current-page))) (cond (jao-river-enabled (jao-river-open-with-zathura f p)) (jao-sway-enabled (jao-sway-open-with-zathura f p)) @@ -1652,7 +1652,7 @@ (interactive "P") ,@prelude (let ((jao-use-vterm (if term (not jao-use-vterm) jao-use-vterm))) - (if-let* ((b (jao-term--find ,cmd))) + (if-let ((b (jao-term--find ,cmd))) (pop-to-buffer b) (jao-exec-in-term ,cmd ,(format "*%s*" name)))))) @@ -2596,7 +2596,7 @@ :config (defun jao-ement-track (event room session) (when (ement-notify--room-unread-p event room session) - (when-let* ((n (ement-room--buffer-name room)) + (when-let ((n (ement-room--buffer-name room)) (b (get-buffer n))) (tracking-add-buffer b)))) @@ -2622,7 +2622,7 @@ (defun jao-mastodon-toot-url () (interactive) - (when-let* ((url (jao-url-around-point t))) + (when-let (url (jao-url-around-point t)) (jao-tracking-go-to-chats) (mastodon-toot--compose-buffer nil nil nil url))) @@ -3136,7 +3136,7 @@ (defun jao-set-wallpaper (&optional path) (interactive) (let ((current (format "~/.wallpaper.%s" (jao-colors-scheme)))) - (when-let* ((f (or (and path (expand-file-name path)) + (when-let ((f (or (and path (expand-file-name path)) (read-file-name "Image: " jao-wallpaper-dir (file-symlink-p current) |