refactor(config): Clean up and reorganize Emacs configuration

Remove unused packages (EMMS, jinx, god-mode), simplify terminal
setup with ido instead of vertico/orderless, and reorganize
keybindings. Add new packages (debase, discomfort, git-timemachine,
edit-indirect) and improve EXWM, dired, and theme
configurations. Move restart-fcitx5 to kbd-func and update Linux
PATH for Guix.
This commit is contained in:
2026-05-30 22:59:25 +08:00
parent 42c3e3600c
commit ccd5c085f8
19 changed files with 143 additions and 226 deletions

View File

@@ -9,31 +9,11 @@
(interactive)
(find-file "~/.emacs.d/init.el"))
(defun duplicate-and-move-to-next-line()
"Duplicate current line and move to next line."
(interactive)
(progn
(duplicate-line)
(next-line)))
;; scratch buffer
(if *is-mac*
(general-def "C-c <f12>" 'scratch-buffer)
(general-def "C-c <delete>" 'scratch-buffer))
;; god-mode
(general-def god-local-mode-map
"i" 'god-mode-all
"<escape>" 'god-mode-all
"[" 'backward-paragraph
"]" 'forward-paragraph
"." 'repeat
"y" 'yank
"C-c C-<f12>" 'scratch-buffer
"z" 'avy-goto-char
"'" 'avy-goto-word-1
"<f2>" 'open-init-file)
;; global map with C-c prefix
(general-def
:prefix "C-c"
@@ -45,23 +25,18 @@
;; global map
(general-def
;; god-mode
"<escape>" 'god-mode-all
"M-i" 'god-mode-all
;; buffer, file, and window
"<f2>" 'open-init-file
"M-[" 'previous-buffer
"M-]" 'next-buffer
"C-x C-b" 'ibuffer-other-window
"C-x K" 'crux-kill-other-buffers
"C-x C-b" 'ibuffer-other-window
;; edit
"M-c" 'capitalize-dwim
"M-u" 'upcase-dwim
"M-l" 'downcase-dwim
"C-," 'duplicate-and-move-to-next-line
"C-," 'crux-duplicate-current-line-or-region
"C-k" 'crux-smart-kill-line
"C-<backspace>" 'crux-kill-line-backwards
"C-a" 'crux-move-beginning-of-line
@@ -70,10 +45,12 @@
"C-c C-DEL" 'hungry-delete-forward
"M-P" 'drag-stuff-up
"M-N" 'drag-stuff-down
"C-M-@" 'er/mark-symbol
"M-@" 'er/mark-word
;; undo
"C-/" 'undo-fu-only-undo
"C-?" 'undo-fu-only-redo
"C-/" 'undo
"C-M-_" 'undo-redo
;; navigate
"M-p" 'backward-paragraph