From 0383ed224a7708315f3da83d5e809c597b0e888a Mon Sep 17 00:00:00 2001 From: Yuchen Pei Date: Sat, 14 Oct 2023 12:18:38 +1100 Subject: [emacs] Fix notes and shell cycle and creation. One function to switch or cycle default notes indirect buffers. One to switch or cycle shell mode buffers. --- emacs/.emacs.d/init/ycp-buffer.el | 2 +- emacs/.emacs.d/init/ycp-complete.el | 2 ++ emacs/.emacs.d/init/ycp-org.el | 2 +- emacs/.emacs.d/init/ycp-prog.el | 2 +- 4 files changed, 5 insertions(+), 3 deletions(-) (limited to 'emacs/.emacs.d/init') diff --git a/emacs/.emacs.d/init/ycp-buffer.el b/emacs/.emacs.d/init/ycp-buffer.el index 6096869..3629efe 100644 --- a/emacs/.emacs.d/init/ycp-buffer.el +++ b/emacs/.emacs.d/init/ycp-buffer.el @@ -37,7 +37,7 @@ "M-s v" #'my-buffers-vc-root ;; F7: Cycle or create buffers with the same base buffer as the ;; current buffer - "" #'my-create-or-switch-indirect-buffers + "" #'my-create-or-switch-indirect-buffers ;; F8: Cycle or create buffers with the same major mode as the ;; current buffer "" #'my-buffer-create-or-cycle-same-mode diff --git a/emacs/.emacs.d/init/ycp-complete.el b/emacs/.emacs.d/init/ycp-complete.el index f76ebbb..285c6c9 100644 --- a/emacs/.emacs.d/init/ycp-complete.el +++ b/emacs/.emacs.d/init/ycp-complete.el @@ -241,6 +241,8 @@ (:install t) (:delay 10) (setq marginalia-max-relative-age 0) + (my-keybind minibuffer-local-map + "M-A" #'marginalia-cycle) (marginalia-mode 1)) (setq tempel-path diff --git a/emacs/.emacs.d/init/ycp-org.el b/emacs/.emacs.d/init/ycp-org.el index 221eaf7..b20f33e 100644 --- a/emacs/.emacs.d/init/ycp-org.el +++ b/emacs/.emacs.d/init/ycp-org.el @@ -440,7 +440,7 @@ (my-package my-org (:delay 10) (my-keybind global-map - "" #'my-org-open-default-notes-file) + "" #'my-org-open-or-cycle-notes) (my-keybind org-mode-map "C-c 1" #'my-org-insert-date-range "C-c ns" #'my-org-substitute-gnus-link-after-archiving diff --git a/emacs/.emacs.d/init/ycp-prog.el b/emacs/.emacs.d/init/ycp-prog.el index 6696aaf..222e912 100644 --- a/emacs/.emacs.d/init/ycp-prog.el +++ b/emacs/.emacs.d/init/ycp-prog.el @@ -120,7 +120,7 @@ '(shell-mode . my-shell-with-directory)) (my-keybind comint-mode-map "" #'my-comint-restart) (add-hook 'shell-mode-hook 'my-shell-disable-company-if-remote) - (my-keybind global-map "" #'my-switch-or-create-shell-buffer) + (my-keybind global-map "" #'my-shell-open-or-cycle) ) (my-package eshell -- cgit v1.2.3