diff options
| author | Craig Jennings <c@cjennings.net> | 2025-07-13 18:38:35 -0500 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2025-07-13 18:38:35 -0500 |
| commit | e0d8e0c268935d9836bc3516222b3d4306899095 (patch) | |
| tree | 2c869e3af34778cdd0b3908a8c68bc30fbed4062 /modules | |
| parent | 642dd170a1b69a125b36b90e34d01dd7f6378218 (diff) | |
| download | dotemacs-e0d8e0c268935d9836bc3516222b3d4306899095.tar.gz dotemacs-e0d8e0c268935d9836bc3516222b3d4306899095.zip | |
consolidate dashboard keybinding to f4 only
Diffstat (limited to 'modules')
| -rw-r--r-- | modules/dashboard-config.el | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/modules/dashboard-config.el b/modules/dashboard-config.el index 45be1a55..c6c32cc6 100644 --- a/modules/dashboard-config.el +++ b/modules/dashboard-config.el @@ -53,18 +53,21 @@ (defun cj/display-dashboard () "Display dashboard, create if it doesn't exist." (interactive) - (dired-sidebar-hide-sidebar) ;; hide dired-sidebar if displaying - (get-buffer-create "*dashboard*") - (pop-to-buffer "*dashboard*") - (delete-other-windows)) -(global-set-key (kbd "<f4>") 'cj/display-dashboard) + (dired-sidebar-hide-sidebar) + (if (get-buffer "*dashboard*") + (progn + (pop-to-buffer "*dashboard*") + (delete-other-windows)) + (dashboard-open))) ;; --------------------------------- Dashboard --------------------------------- ;; a useful startup screen for Emacs (use-package dashboard :demand t ;; needed to startup quickly - :bind ("<f9>" . dashboard-open) + :init + (global-unset-key (kbd "<f4>")) + :bind ("<f4>" . cj/display-dashboard) :custom (dashboard-projects-backend 'projectile) |
