nixos/home/emacs/modules/custom-org-config.el
Evie Litherland-Smith 5c959f8bf5 Reorganise a bunch of elisp file
Set package priority manually rather than using
crafted-early-init-config

Copy crafted-defaults-config to custom-defaults-config instead

Move some things out of init.el into relevant custom config files

Add some new packages (to be configured)
2023-10-27 08:03:51 +01:00

38 lines
1.1 KiB
EmacsLisp

(setq org-directory "~/Org"
org-journal-dir "~/Org/journal/"
org-journal-file-type 'daily
org-journal-file-format "%Y%m%d.org"
org-agenda-files '("~/Org/")
org-agenda-sticky t
org-agenda-prefix-format '((agenda . " %i %t %s")
(todo . " %i")
(tags . " %i")
(search . " %i"))
org-refile-use-outline-path t
org-refile-allow-creating-parent-nodes t
org-refile-targets '((nil :maxlevel . 3)
(org-agenda-files :maxlevel . 3)))
(defun my/org-move-done-tasks-to-bottom ()
"Sort all tasks in the topmost heading by TODO state."
(interactive)
(save-excursion
(while (org-up-heading-safe))
(org-sort-entries nil ?o))
;; Reset the view of TODO items
(org-overview)
(org-show-entry)
(org-show-children))
(when (require 'org nil :noerror)
(add-hook
'org-mode-hook
(lambda () (add-hook
'before-save-hook
#'my/org-move-done-tasks-to-bottom
nil
'local))))
(provide 'custom-org-config)