doom

My literate doom emacs config
git clone https://github.com/michaelneuper/doom.git
Files | Log | Refs

commit f706224f9c9eb5132c5b10634496096a5248a585
parent 80da13cb7f468c58d81c806a564d3e312229fbc9
Author: michaelneuper <michael@michaelneuper.com>
Date:   Mon, 26 May 2025 13:51:21 +0200

update evil, dired and pdf-tools config

- enable fine-undo in evil-mode
- enable dragndrop for dired
- hide dotfiles by default
- add pdf keybindings
- enable midnight-mode by default in pdf's

Diffstat:
Mconfig.org | 38++++++++++++++++++++++++++++++++++++--
Minit.el | 2+-
2 files changed, 37 insertions(+), 3 deletions(-)

diff --git a/config.org b/config.org @@ -365,15 +365,36 @@ Add padding to emacs frames and windows with [[doom-package:spacious-padding][sp *** evil #+begin_src emacs-lisp (after! evil - (setq evil-move-cursor-back nil ; don't move the block cursor when toggling insert mode - evil-kill-on-visual-paste nil)) ; don't put overwritten text in the kill ring + (setq evil-move-cursor-back nil ; don't move the block cursor when toggling insert mode + evil-kill-on-visual-paste nil ; don't put overwritten text in the kill ring + evil-want-fine-undo t + evil-move-beyond-eol t)) #+end_src ** :emacs *** dired Set =quick-access-entries= for =dirvish=. Ensure [[https://github.com/alexluigit/dirvish/blob/main/docs/CUSTOMIZING.org#install-dependencies-for-an-enhanced-preview-experience][these]] programs are installed to file previews. #+begin_src emacs-lisp +(setq dired-mouse-drag-files t + mouse-drag-and-drop-region-cross-program t) + +(after! dired-x + (setq dired-omit-files ; hide "dotfiles" + (concat dired-omit-files "\\|^\\..*$"))) + +;; FIXME not working +(add-hook! dired-mode (dired-hide-details-mode 1)) + (after! dirvish + (setq dirvish-attributes + (append + ;; The order of these attributes is insignificant, they are always + ;; displayed in the same position. + '(vc-state subtree-state nerd-icons collapse) + ;; Other attributes are displayed in the order they appear in this list. + '(git-msg file-size))) + + (setq! dirvish-quick-access-entries `(("h" "~/" "Home") ("c" "~/Developer/" "Code") @@ -401,6 +422,19 @@ Improve =eglot= performance. :after eglot :config (eglot-booster-mode)) #+end_src +*** pdf +#+begin_src emacs-lisp +;; TODO add continuous scroll +(add-hook 'pdf-view-mode-hook #'pdf-view-midnight-minor-mode) + +(map! :map pdf-view-mode-map + :localleader + (:prefix ("h" . "history") + :desc "Go forward in history" + "f" #'pdf-history-forward + :desc "Go backward in history" + "b" #'pdf-history-backward)) +#+end_src ** :lang *** cc Set indentation level for =cc-mode= to 2. diff --git a/init.el b/init.el @@ -138,7 +138,7 @@ ;;nim ; python + lisp at the speed of c ;;nix ; I hereby declare "nix geht mehr!" ;;ocaml ; an objective camel - (org +roam2 +dragndrop +pretty) ; organize your plain life in plain text + (org +roam2 +dragndrop +gnuplot +pretty) ; organize your plain life in plain text ;;php ; perl's insecure younger brother ;;plantuml ; diagrams for confusing people more ;;graphviz ; diagrams for confusing yourself even more