diff options
author | Marc Coquand <marc@mccd.space> | 2024-11-14 10:13:14 +0200 |
---|---|---|
committer | Marc Coquand <marc@mccd.space> | 2024-11-14 10:13:14 +0200 |
commit | 5a36268deea891c849bf30a409af0da133cab4d9 (patch) | |
tree | c4afacdd1eddf5d279af2037a24c715a4e024acd /home/dots/.emacs | |
parent | 8d2b7bd80aeca69b44565ff80ee0349e5fc550b1 (diff) | |
download | guix-5a36268deea891c849bf30a409af0da133cab4d9.tar.gz guix-5a36268deea891c849bf30a409af0da133cab4d9.tar.bz2 guix-5a36268deea891c849bf30a409af0da133cab4d9.zip |
.
Diffstat (limited to 'home/dots/.emacs')
-rw-r--r-- | home/dots/.emacs | 105 |
1 files changed, 61 insertions, 44 deletions
diff --git a/home/dots/.emacs b/home/dots/.emacs index c3469f8..229af8a 100644 --- a/home/dots/.emacs +++ b/home/dots/.emacs @@ -142,7 +142,6 @@ (default-frame-alist '((font . "Iosevka SS13 Extended") (height . 150) (line-spacing . 0.5))) - ;; undo (undo-limit 10000000) (undo-outer-limit 20000000) (tab-always-indent 'complete) @@ -240,6 +239,10 @@ :config (window-divider-mode)) +(use-package window + :config + (add-to-list 'display-buffer-alist '("*Async Shell Command*" display-buffer-no-window (nil)))) + (use-package files :config (setq delete-old-versions t @@ -428,6 +431,7 @@ ("p" . git-gutter:previous-hunk)) :ensure t) + (use-package git-gutter-fringe :ensure t) @@ -459,7 +463,6 @@ :init (pinentry-start)) - (use-package epa-file :custom (epa-pinentry-mode 'loopback) @@ -772,8 +775,6 @@ (interactive) (async-shell-command "org-sync")) -(add-to-list 'display-buffer-alist '("*Async Shell Command*" display-buffer-no-window (nil))) - ;; Org (use-package org :ensure t @@ -783,18 +784,14 @@ (org-agenda-files :maxlevel . 4))) (org-default-notes-file "~/personal-db/notes/todo.org") (org-hide-emphasis-markers t) - (org-agenda-include-diary nil) - (org-agenda-remove-tags t) + (org-enforce-todo-dependencies t) (org-link-keep-stored-after-insertion t) (org-startup-folded t) (org-todo-keywords '((sequence "TODO" "DONE"))) - (org-agenda-inhibit-startup nil) - ;; Add /New Heading at the end for use (org-refile-allow-creating-parent-nodes 'confirm) (org-outline-path-complete-in-steps nil) (org-refile-use-outline-path 'file) - ;; Otherwise looks weird in variable-pitch-mode (org-log-done 'time) (org-capture-templates '(("t" "Todo" @@ -855,18 +852,6 @@ (set-face-attribute 'org-property-value nil :inherit 'fixed-pitch) (set-face-attribute 'org-special-keyword nil :inherit 'fixed-pitch) (set-face-attribute 'org-meta-line nil :inherit 'fixed-pitch) - (global-set-key (kbd "C-c l") #'org-store-link) - (global-set-key (kbd "C-c a") #'org-agenda) - (global-set-key (kbd "C-c c") #'org-capture) - (global-set-key (kbd "C-c j") #'org-goto) - (global-set-key (kbd "C-c C-o") #'org-open-at-point-global) - ;; Something errors out with capture logs and non-org files - (add-to-list 'warning-suppress-log-types '(org-element)) - (add-to-list 'warning-suppress-types '(org-element)) - (advice-add 'org-agenda-quit :before (lambda () - (interactive) - (org-save-all-org-buffers) - (sync-org))) :hook ((org-mode . org-indent-mode) (org-capture-after-finalize . sync-org) @@ -882,6 +867,38 @@ :custom (org-id-link-to-org-use-id 'create-if-interactive-and-no-custom-id)) +(use-package subr + :bind + (("C-c C-o" . org-open-at-point-global))) + +(use-package ol + :bind + (("C-c l" . org-link))) + +(use-package org-capture + :bind + (("C-c l" . org-capture))) + +(defun org-agenda-switch-to-narrowed-subtree () + (interactive) + (org-agenda-switch-to) + (org-narrow-to-subtree)) + +(use-package org-agenda + :custom + (org-agenda-remove-tags t) + (org-agenda-inhibit-startup nil) + :config + (advice-add 'org-agenda-quit :before (lambda () + (interactive) + (org-save-all-org-buffers) + (sync-org))) + :bind + (("C-c a" . org-agenda) + ("C-c l") + :map org-agenda-mode-map + ("<return>" . org-agenda-switch-to-narrowed-subtree))) + (use-package autorevert :diminish auto-revert-mode) @@ -1052,34 +1069,35 @@ (use-package elfeed :ensure t + :custom + (elfeed-use-curl t) + ;; setup feeds + (elfeed-protocol-fever-update-unread-only t) + (elfeed-protocol-fever-fetch-category-as-tag t) + (elfeed-protocol-feeds '(("fever+https://freshrss@rss.mccd.space" + :api-url "https://rss.mccd.space/api/fever.php" + :password (shell-command-to-string "pass show mccd/freshrss")))) + ;; enable elfeed-protocol + (elfeed-protocol-enabled-protocols '(fever)) + (elfeed-curl-extra-arguments '("--insecure")) + :bind + (("C-x w" . elfeed)) :config - (setq elfeed-use-curl t - ;; setup feeds - elfeed-protocol-fever-update-unread-only t - elfeed-protocol-fever-fetch-category-as-tag t - elfeed-protocol-feeds '(("fever+https://freshrss@rss.mccd.space" - :api-url "https://rss.mccd.space/api/fever.php" - :password (shell-command-to-string "pass show mccd/freshrss"))) - ;; enable elfeed-protocol - elfeed-protocol-enabled-protocols '(fever) - elfeed-curl-extra-arguments '("--insecure")) ; necessary for https without a trust certificate - (elfeed-set-timeout 36000) - (global-set-key (kbd "C-x w") 'elfeed)) + ;; necessary for https without a trust certificate + (elfeed-set-timeout 36000)) (use-package mastodon :defer t - :config - (setq - mastodon-active-user "marcc" - mastodon-instance-url "https://fosstodon.org")) + :custom + (mastodon-active-user "marcc") + (mastodon-instance-url "https://fosstodon.org")) (use-package eww - :config - (setq - browse-url-browser-function 'eww-browse-url ; Use eww as the default browser - eww-search-prefix "https://lite.duckduckgo.com/lite/?q=" - shr-max-image-proportion 0.3 - shr-width 70)) + :custom + (browse-url-browser-function 'eww-browse-url) ; Use eww as the default browser + (eww-search-prefix "https://lite.duckduckgo.com/lite/?q=") + (shr-max-image-proportion 0.3) + (shr-width 70)) ;; Can play youtube urls and music. ;; Requires mpv @@ -1093,7 +1111,6 @@ (emms-all) (emms-default-players)) - (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. |