From 57f8848b4e7e16d96107d9195dedd5c8a9a7b0f9 Mon Sep 17 00:00:00 2001 From: rostyhn Date: Tue, 21 Sep 2021 21:15:19 -0700 Subject: [PATCH] more org-roam stuff --- emacs | 2 -- emacs_home.el | 48 ++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 46 insertions(+), 4 deletions(-) diff --git a/emacs b/emacs index 6922f86..f7e2e43 100644 --- a/emacs +++ b/emacs @@ -149,8 +149,6 @@ Return a list of installed packages or nil for every skipped package." ("s-p" . projectile-command-map) ("C-c p" . projectile-command-map))) -(global-hl-todo-mode 1) - ;; org settings (setq org-replace-disputed-keys t) (define-key global-map "\C-cl" 'org-store-link) diff --git a/emacs_home.el b/emacs_home.el index f41d36f..8208f61 100644 --- a/emacs_home.el +++ b/emacs_home.el @@ -12,15 +12,58 @@ (setq org-roam-v2-ack t) :custom (org-roam-directory "~/Documents/slipbox") + (org-roam-capture-templates + '(("d" "default" plain + "%?" + :if-new (file+head "%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n") + :unnarrowed t) + ("b" "book notes" plain + "\n* Source\n\nAuthor: %^{Author}\nTitle: ${title}\nYear: %^{Year}\n\n %?" + :if-new (file+head "%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n") + :unnarrowed t))) (org-roam-completion-everywhere t) + (org-roam-completion-system 'default) + (org-roam-dailies-directory "daily/") + (org-roam-dailies-capture-templates + '(("d" "default" entry + #'org-roam-capture--get-point + "* %?" + :file-name "Journal/%<%Y-%m-%d>" + :head "#+title: %<%Y-%m-%d %a>\n\n[[roam:%<%Y-%B>]]\n\n") + ("t" "Task" entry + #'org-roam-capture--get-point + "* TODO %?\n %U\n %a\n %i" + :file-name "Journal/%<%Y-%m-%d>" + :olp ("Tasks") + :empty-lines 1 + :head "#+title: %<%Y-%m-%d %a>\n\n[[roam:%<%Y-%B>]]\n\n") + ("j" "journal" entry + #'org-roam-capture--get-point + "* %<%I:%M %p> - Journal :journal:\n\n%?\n\n" + :file-name "Journal/%<%Y-%m-%d>" + :olp ("Log") + :head "#+title: %<%Y-%m-%d %a>\n\n[[roam:%<%Y-%B>]]\n\n") + ("m" "meeting" entry + #'org-roam-capture--get-point + "* %<%I:%M %p> - %^{Meeting Title} :meetings:\n\n%?\n\n" + :file-name "Journal/%<%Y-%m-%d>" + :olp ("Log") + :head "#+title: %<%Y-%m-%d %a>\n\n[[roam:%<%Y-%B>]]\n\n"))) :bind (("C-c n l" . org-roam-buffer-toggle) ("C-c n f" . org-roam-node-find) ("C-c n i" . org-roam-node-insert) + ("C-c n d" . org-roam-dailies-find-date) + ("C-c n c" . org-roam-dailies-capture-today) + ("C-c n C r" . org-roam-dailies-capture-tomorrow) + ("C-c n t" . org-roam-dailies-find-today) + ("C-c n y" . org-roam-dailies-find-yesterday) + ("C-c n r" . org-roam-dailies-find-tomorrow) :map org-mode-map - ("C-M-i" . completion-at-point) + ("C-M-i" . completion-at-point)) :config + (require 'org-roam-dailies) (org-roam-setup) - (org-roam-db-autosync-mode))) + (org-roam-db-autosync-mode)) (add-to-list 'auto-mode-alist '("neomutt" . mail-mode)) (setq appt-message-warning-time 15 @@ -33,6 +76,7 @@ (notify-send (format "Appointment in %s minute(s)" min-to-app) msg)) (add-hook 'mail-mode-hook 'flyspell-mode 1) +(add-hook 'org-mode-hook 'flyspell-mode 1) (setq appt-disp-window-function (function facade-notify-appt)) (provide 'emacs_home)