Update calendar and agenda settings

Remove gnus-icalendar, rely on khalel-icalendar

Change org file structure
This commit is contained in:
Evie Litherland-Smith 2024-10-01 17:58:04 +01:00
parent 9a18bfcaf2
commit 12d5b8182e

View file

@ -330,25 +330,13 @@ Rules and packages for buffer management and window navigation.
(window-height . 0.2) (window-height . 0.2)
(window-parameters . ((no-delete-other-windows . t)))))) (window-parameters . ((no-delete-other-windows . t))))))
(use-package gnus-icalendar
:after (org-agenda)
:custom
(gnus-icalendar-org-capture-file (expand-file-name "calendar/email.org" org-directory))
(gnus-icalendar-org-capture-headline '("Inbox"))
:config
(require 'org-agenda)
(require 'org-capture)
(gnus-icalendar-org-setup))
(use-package mu4e-icalendar (use-package mu4e-icalendar
:after (mu4e org-agenda khalel) :after (mu4e org-agenda)
:functions (mu4e-icalendar-setup)
:custom :custom
(mu4e-icalendar-trash-after-reply nil) (mu4e-icalendar-trash-after-reply nil)
:config :config
(require 'gnus-icalendar) (mu4e-icalendar-setup))
(mu4e-icalendar-setup)
(gnus-icalendar-org-setup)
(require 'khalel-icalendar))
#+end_src #+end_src
*** Khalel *** Khalel
#+begin_src emacs-lisp #+begin_src emacs-lisp
@ -358,7 +346,7 @@ Rules and packages for buffer management and window navigation.
:functions (khalel-add-capture-template) :functions (khalel-add-capture-template)
:hook (org-agenda-mode . khalel-import-events) :hook (org-agenda-mode . khalel-import-events)
:config :config
(khalel-add-capture-template "e") (khalel-add-capture-template)
:custom :custom
(khalel-default-alarm "10") (khalel-default-alarm "10")
(khalel-default-calendar "calendar") (khalel-default-calendar "calendar")
@ -449,8 +437,8 @@ Configure email with iCalendar event support, to integrate with
personal)) personal))
:config :config
(setq mu4e-use-fancy-chars t) (setq mu4e-use-fancy-chars t)
(require 'mu4e-icalendar)
) (require 'khalel-icalendar))
(with-eval-after-load 'mu4e (with-eval-after-load 'mu4e
(require 'mu4e-context) (require 'mu4e-context)
@ -808,7 +796,7 @@ Configure email with iCalendar event support, to integrate with
("<remap> <org-goto>" . consult-org-heading)) ("<remap> <org-goto>" . consult-org-heading))
:custom :custom
(org-directory "~/Documents/org") (org-directory "~/Documents/org")
(org-default-notes-file (expand-file-name "roam/inbox.org" org-directory)) (org-default-notes-file (expand-file-name "notes.org" org-directory))
(org-archive-default-command #'org-archive-to-archive-sibling) (org-archive-default-command #'org-archive-to-archive-sibling)
(org-hide-emphasis-markers nil) (org-hide-emphasis-markers nil)
(org-use-sub-superscripts '{}) (org-use-sub-superscripts '{})
@ -901,14 +889,16 @@ Configure email with iCalendar event support, to integrate with
:after org :after org
:bind (("C-c n n" . org-capture)) :bind (("C-c n n" . org-capture))
:custom (org-capture-templates :custom (org-capture-templates
'(("n" "Inbox" entry '(("n" "Note" entry
(file+datetree "inbox.org")) (file+olp "notes.org" "Inbox"))
("t" "TODO" entry ("t" "Task" entry
(file+olp "roam/tasks.org" "Inbox") (file+olp "tasks.org" "Inbox")
"* TODO %?\nDEADLINE: %t\n %i\n %a") "* TODO %?\nDEADLINE: %t\n %i\n %a")
("#" "used by gnus-icalendar-org" entry ("#" "used by gnus-icalendar-org" entry
(file+olp "calendar/email.org" "Inbox") (file+olp "calendar/email.org" "Inbox")
"%i" :immediate-finish t)))) "%i" :immediate-finish t)))
:config
(with-eval-after-load 'khalel (khalel-add-capture-template)))
(when (or (package-installed-p 'emacsql-sqlite) (when (or (package-installed-p 'emacsql-sqlite)
(package-installed-p 'emacsql-sqlite-builtin)) (package-installed-p 'emacsql-sqlite-builtin))
@ -995,10 +985,7 @@ Configure email with iCalendar event support, to integrate with
(org-agenda-files (list (org-agenda-files (list
(expand-file-name org-directory) (expand-file-name org-directory)
(expand-file-name "calendar" org-directory) (expand-file-name "calendar" org-directory)
(expand-file-name "inbox.org" org-directory) (expand-file-name "roam/journal.org" org-directory)))
(expand-file-name "roam/tasks.org" org-directory)
(expand-file-name "roam/journal.org" org-directory)
(expand-file-name "roam/analysis_notes.org" org-directory)))
:config :config
(appt-activate +1)) (appt-activate +1))