- 新增 init-dired.el 基础配置 - 调整 corfu 初始化方式 - 修改 dashboard 显示设置和快捷键 - 更新键位绑定 - 调整 org-journal 格式 - 修复 scratch buffer 模式设置 - 更新主题颜色
36 lines
1.7 KiB
EmacsLisp
36 lines
1.7 KiB
EmacsLisp
;;; init-dashboard.el --- dashboard -*- lexical-binding: t -*-
|
|
|
|
;;; Commentary:
|
|
|
|
;;; Code:
|
|
|
|
(use-package dashboard
|
|
:demand t
|
|
:config
|
|
(dashboard-setup-startup-hook)
|
|
(setq dashboard-banner-logo-title (format "%s" emacs-version))
|
|
(setq dashboard-banner-ascii " ##### # # # # ####### # # # ##### ##### \n# # ## # # # # ## ## # # # # # # \n# # # # # # # # # # # # # # # \n# #### # # # # # ##### # # # # # # ##### \n# # # # # # # # # # ####### # # \n# # # ## # # # # # # # # # # # \n ##### # # ##### ####### # # # # ##### ##### ")
|
|
(setq dashboard-startup-banner 'ascii)
|
|
(setq dashboard-center-content t)
|
|
(setq dashboard-navigation-cycle t)
|
|
(setq dashboard-items '((recents . 15)
|
|
(bookmarks . 5)
|
|
(projects . 5)))
|
|
(add-hook 'emacs-startup-hook
|
|
(lambda()
|
|
(setq my-emacs-startup-time (format-time-string "%Y-%m-%d %H:%M:%S"))))
|
|
(defun my/dashboard-insert-copyright ()
|
|
"Insert copyright in the footer."
|
|
(dashboard-insert-center
|
|
(propertize (format "\n\nEmacs started at %s" my-emacs-startup-time)
|
|
'face 'font-lock-comment-face)))
|
|
(advice-add #'dashboard-insert-footer :after #'my/dashboard-insert-copyright)
|
|
(setq dashboard-footer-messages '(
|
|
"Hello."
|
|
"Hi."
|
|
))
|
|
(setq dashboard-item-shortcuts '((recents . "r") (bookmarks . "b") (projects . "p") (agenda . "a") (registers . "e"))))
|
|
|
|
(provide 'init-dashboard)
|
|
;;; init-dashboard.el ends here
|