nix-conf/home-manager/emacs/doom/config.el
Thiago Sposito 0251529a8a
feat: add email integration with mu4e and protonmail-bridge
- Configure mu4e in Doom Emacs with Proton mail account
- Add protonmail-bridge service and mbsync/msmtp for mail sync
- Integrate sops-nix for secrets management (mail password)
- Create mail.nix with full IMAP/SMTP configuration
- Add ComfyUI user service module
- Add custom ASCII banner for Doom dashboard
- Enable nix module in Doom Emacs
- Add force-quit gnome extension
- Ignore secrets directory in git
- also add comfy-ui
2026-01-18 21:14:44 -03:00

77 lines
2.3 KiB
EmacsLisp

;;; $DOOMDIR/config.el -*- lexical-binding: t; -*-
;; Add NixOS mu4e to load-path
(let ((mu4e-dir (car (file-expand-wildcards "~/.nix-profile/share/emacs/site-lisp/elpa/mu4e-*"))))
(when mu4e-dir
(add-to-list 'load-path mu4e-dir)))
(add-hook 'scheme-mode-hook #'smartparens-strict-mode)
(defun my-doom-ascii-banner ()
(let ((banner-file (expand-file-name "banner.txt" doom-user-dir)))
(when (file-exists-p banner-file)
(insert-file-contents banner-file))))
(setq +doom-dashboard-ascii-banner-fn #'my-doom-ascii-banner)
(use-package! lsp-mode
:config
(add-to-list 'lsp-language-id-configuration '(fennel-mode . "fennel"))
(lsp-register-client
(make-lsp-client :new-connection (lsp-stdio-connection "fennel-ls")
:activation-fn (lsp-activate-on "fennel")
:server-id 'fennel-ls)))
(add-hook 'fennel-mode-hook #'lsp!)
(setq user-full-name "Thiago Sposito"
user-mail-address "th.spo@pm.me")
(setq doom-font (font-spec :family "FiraCode Nerd Font Mono" :size 22 :weight 'semi-light)
doom-variable-pitch-font (font-spec :family "FiraCode Nerd Font" :size 18))
(setq doom-theme 'doom-one)
(setq display-line-numbers-type t)
(setq org-directory "~/org/")
(after! treemacs
(treemacs-follow-mode 1)
(treemacs-project-follow-mode 1))
(add-hook 'window-setup-hook #'treemacs)
(setq shell-file-name (executable-find "zsh")
explicit-shell-file-name shell-file-name)
(set-popup-rule! "^\\*vterm"
:side 'bottom
:size 0.3
:select t
:quit t
:ttl nil)
(map! :desc "Toggle terminal (vterm)"
"C-~" #'vterm)
(after! mu4e
(setq mu4e-get-mail-command "mbsync -a"
mu4e-update-interval 300
mu4e-maildir "~/Maildir"
mu4e-change-filenames-when-moving t
sendmail-program "msmtp"
send-mail-function #'sendmail-send-it
message-sendmail-f-is-evil t
message-sendmail-extra-arguments '("--read-envelope-from")
message-send-mail-function #'message-send-mail-with-sendmail)
(set-email-account! "Proton"
'((mu4e-sent-folder . "/proton/Sent")
(mu4e-drafts-folder . "/proton/Drafts")
(mu4e-trash-folder . "/proton/Trash")
(mu4e-refile-folder . "/proton/Archive")
(user-mail-address . "th.spo@pm.me")
(user-full-name . "Thiago Sposito"))
t))