feat: add dashboard and enhance completion

- Add startup dashboard with recent files and bookmarks
- Enhance corfu with icons and minibuffer transfer
- Add avy-zap, markdown-mode, consult-dir
- Optimize GC settings and editor config
This commit is contained in:
trogloxene
2026-04-02 14:56:29 +08:00
parent 9ecad315b5
commit c7352d0460
10 changed files with 311 additions and 76 deletions

View File

@@ -43,7 +43,7 @@
(format-time-string "%a" time)
(format-time-string "%Y-%m-%d %a" time)))
org-journal-carryover-items "TODO=\"TODO\"|TODO=\"STARTED\"|TODO=\"WAITING\"|TODO=\"SOMEDAY\"")
(when *is-windows*
(setq org-journal-dir "D:/emacs/my-org-daily/"))
@@ -60,14 +60,14 @@
(goto-char day-end)
(insert "\n\n** daily\n\n\n")
(insert "** tasks\n")))))
(add-hook 'org-journal-after-header-create-hook #'my/journal-setup-new-day)
(defun my/journal-position-cursor-after-time ()
(when (derived-mode-p 'org-journal-mode)
(org-back-to-heading)
(end-of-line)))
(add-hook 'org-journal-after-entry-create-hook #'my/journal-position-cursor-after-time)
(defun org-journal-open-entry-for-editing (&optional event)
@@ -109,7 +109,7 @@
(add-hook 'org-journal-mode-hook
(lambda ()
(global-cns-mode-enable-in-buffer)))
;; 一些随org-mode加载的基础配置
(add-hook 'org-mode-hook
(lambda ()
@@ -156,8 +156,7 @@
(when *is-windows*
(with-eval-after-load 'org
(setq org-agenda-files '("d:/emacs/hugo/this-is-my-blog/all-blog.org"
"d:/emacs/my-org-daily/"
"d:/emacs/my-org-daily/"))))
"d:/emacs/my-org-daily/"))))
(when *is-mac*
(with-eval-after-load 'org
(setq org-agenda-files '("~/org/my-org-daily"))))
@@ -271,18 +270,18 @@ See `org-capture-templates' for more information."
(let* ((blog-dir "d:/emacs/hugo/this-is-my-blog/")
(timestamp (format-time-string "%Y-%m-%d %H:%M:%S"))
(default-directory blog-dir))
;; save buffer
(save-buffer)
;; git add
(message "Adding files...")
(eshell-command "git add .")
;; git commit with timestamp
(message "Committing: %s" timestamp)
(eshell-command (format "git commit -m \"Update: %s\"" timestamp))
;; git push
(message "Pushing to remote...")
(let ((exit-code (eshell-command "git push")))