diff options
-rw-r--r-- | init.el | 119 |
1 files changed, 119 insertions, 0 deletions
diff --git a/init.el b/init.el index feb26ad..b2967aa 100644 --- a/init.el +++ b/init.el | |||
@@ -630,3 +630,122 @@ | |||
630 | (put 'if 'common-lisp-indent-function 2) | 630 | (put 'if 'common-lisp-indent-function 2) |
631 | (put 'dotimes-protect 'common-lisp-indent-function | 631 | (put 'dotimes-protect 'common-lisp-indent-function |
632 | (get 'when 'common-lisp-indent-function)) | 632 | (get 'when 'common-lisp-indent-function)) |
633 | |||
634 | |||
635 | ;; Dired | ||
636 | (use-package dired | ||
637 | :straight nil | ||
638 | :init | ||
639 | (setq-default dired-recursive-copies 'always | ||
640 | dired-recursive-deletes 'always | ||
641 | delete-by-moving-to-trash t | ||
642 | dired-listing-switches "-AFgho --group-directories-first" | ||
643 | dired-dwim-target t) | ||
644 | :bind ("C-x C-j" . dired-jump)) | ||
645 | (defun hook--dired-mode () | ||
646 | (hl-line-mode +1) | ||
647 | (dired-hide-details-mode +1)) | ||
648 | (add-hook 'dired-mode-hook #'hook--dired-mode) | ||
649 | |||
650 | (use-package dired-subtree | ||
651 | :bind (:map dired-mode-map | ||
652 | ("i" . dired-subtree-toggle))) | ||
653 | |||
654 | (use-package dired-collapse | ||
655 | :hook dired-mode) | ||
656 | |||
657 | (use-package 0x0 | ||
658 | :straight (:repo "https://git.sr.ht/~zge/nullpointer-emacs") | ||
659 | :init (setq 0x0-default-service 'ttm) | ||
660 | :commands (0x0-upload | ||
661 | 0x0-upload-file | ||
662 | 0x0-upload-string | ||
663 | 0x0-upload-kill-ring | ||
664 | 0x0-popup)) | ||
665 | |||
666 | (use-package elpher | ||
667 | :straight (:repo "git://thelambdalab.xyz/elpher.git") | ||
668 | :commands (elpher elpher-bookmarks) | ||
669 | :init (setq elpher-ipv4-always t | ||
670 | elpher-certificate-directory | ||
671 | (expand-file-name "elpher-certificates/" | ||
672 | acdw/var-dir)) | ||
673 | (add-hook 'elpher-mode-hook #'acdw/reading-mode) | ||
674 | :custom-face | ||
675 | (elpher-gemini-heading1 | ||
676 | ((t (:inherit (modus-theme-heading-1) | ||
677 | :height 1.0)))) | ||
678 | (elpher-gemini-heading2 | ||
679 | ((t (:inherit (modus-theme-heading-2) | ||
680 | :height 1.0)))) | ||
681 | (elpher-gemini-heading3 | ||
682 | ((t (:inherit (modus-theme-heading-3) | ||
683 | :height 1.0)))) | ||
684 | :bind (:map elpher-mode-map | ||
685 | ("n" . elpher-next-link) | ||
686 | ("p" . elpher-prev-link) | ||
687 | ("o" . elpher-follow-current-link) | ||
688 | ("G" . elpher-go-current))) | ||
689 | |||
690 | (use-package gemini-write | ||
691 | :straight (:repo | ||
692 | "https://alexschroeder.ch/cgit/gemini-write" | ||
693 | :fork (:repo "https://tildegit.org/acdw/gemini-write" | ||
694 | :branch "main")) | ||
695 | :after elpher) | ||
696 | |||
697 | (use-package gemini-mode | ||
698 | :straight (:repo "https://git.carcosa.net/jmcbray/gemini.el.git") | ||
699 | :mode "\\.\\(gemini\\|gmi\\)\\'" | ||
700 | :custom-face | ||
701 | (gemini-heading-face-1 | ||
702 | ((t (:inherit (elpher-gemini-heading1))))) | ||
703 | (gemini-heading-face2 | ||
704 | ((t (:inherit (elpher-gemini-heading2))))) | ||
705 | (gemini-heading-face3 | ||
706 | ((t (:inherit (elpher-gemini-heading3)))))) | ||
707 | |||
708 | (use-package nov | ||
709 | :init (setq nov-text-width t) | ||
710 | (add-hook 'nov-mode-hook #'acdw/reading-mode) | ||
711 | :mode ("\\.epub\\'" . nov-mode)) | ||
712 | |||
713 | (use-package undo-fu | ||
714 | :bind (("C-/" . undo-fu-only-undo) | ||
715 | ("C-?" . undo-fu-only-redo))) | ||
716 | (use-package undo-fu-session | ||
717 | :init (setq undo-fu-session-directory (expand-file-name "undo/" | ||
718 | acdw/var-dir) | ||
719 | undo-fu-session-incompatible-files | ||
720 | '("/COMMIT_EDITMSG\\'" "/git-rebase-todo\\'")) | ||
721 | :config (global-undo-fu-session-mode)) | ||
722 | |||
723 | (setq-default set-mark-repeat-command-pop t) ; repeat mark pops w/o prefix | ||
724 | |||
725 | (use-package expand-region | ||
726 | :bind ("C-=" . er/expand-region)) | ||
727 | |||
728 | (use-package goggles | ||
729 | :hook ((text-mode prog-mode) . goggles-mode)) | ||
730 | |||
731 | (use-package anzu | ||
732 | :init (setq search-default-mode t) | ||
733 | :bind (([remap query-replace] . anzu-query-replace-regexp) | ||
734 | ([remap query-replace-regexp] . anzu-query-replace) | ||
735 | :map isearch-mode-map | ||
736 | ([remap isearch-query-replace] . anzu-isearch-query-replace) | ||
737 | ([remap isearch-query-replace-regexp] . | ||
738 | anzu-isearch-query-replace-regexp))) | ||
739 | |||
740 | (use-package iscroll | ||
741 | :hook text-mode) | ||
742 | |||
743 | (setq-default | ||
744 | browse-url-browser-function 'browse-url-firefox | ||
745 | browse-url-new-window-flag t | ||
746 | browse-url-firefox-new-window-is-tab t | ||
747 | shr-max-width fill-column | ||
748 | shr-width fill-column) | ||
749 | |||
750 | (when (eq acdw/system :work) | ||
751 | (add-to-list 'exec-path "C:/Program Files/Mozilla Firefox")) | ||