+org.el 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. ;;; package --- summary +org.el
  2. ;;; lexical-binding: t; -*-
  3. ;;; Commentary:
  4. ;;; Code:
  5. (setq +todo-file "~/org/inbox.org")
  6. (add-hook! :append org-load
  7. (setq org-directory (expand-file-name "~/org/")
  8. org-journal-dir "~/org/journal/"
  9. org-startup-indented t
  10. org-agenda-files (list org-directory)
  11. org-pretty-entities t
  12. org-hide-emphasis-markers t
  13. org-hide-leading-stars t
  14. org-contacts-files '("~/org/contacts.org")
  15. ; attempt to return todo function to spacemacs
  16. evil-org-key-theme '(textobjects navigation additional insert todo)
  17. ;; show actually italicized text instead of /italicized text/
  18. org-agenda-block-separator ""
  19. org-fontify-whole-heading-line t
  20. org-fontify-done-headline t
  21. org-fontify-quote-and-verse-blocks t
  22. org-log-done 'time
  23. org-bullets-face-name (quote org-bullet-face)
  24. org-bullets-bullet-list '("■" "◆" "▲" "▶")
  25. org-capture-templates
  26. '(
  27. ("i" "Send to inbox" entry (file+headline "~/org/inbox.org" "Inbox")
  28. "* TODO %?\n")
  29. ("l" "Send to inbox with link" entry (file+headline "~/org/inbox.org" "Inbox")
  30. "* TODO %?\n %i\n %a")
  31. ("w" "Work diary entry" entry (file "~/org/work_diary.org")
  32. "* %u\n%?\n")
  33. ("n" "Add an idea" entry (file "~/org/ideas.org")
  34. "* %?\nEntered on %U\n"))
  35. org-agenda-include-diary nil
  36. org-todo-keywords
  37. '((sequence "TODO(t)" "NEXT(n)" "WAITING(w)" "MAYBE(m)" "|" "DONE(d)"))
  38. org-todo-keyword-faces
  39. '((("TODO" . (:foreground "red" :weight bold))
  40. ("NEXT" . (:foreground "blue"))
  41. ("MAYBE" . (:foreground "sea green"))
  42. ("WAITING" . (:foreground "forest green")))
  43. ("DONE" . (:foreground "light sea green")))
  44. org-agenda-span 5
  45. org-agenda-start-day "1d"
  46. org-agenda-custom-commands
  47. '(("N" "List all next tasks" ((agenda "" ((org-agenda-span 1)))
  48. (tags "@errand/-DONE") ; should generaly be pretty empty
  49. (tags "@book/NEXT") ; should generaly be pretty empty
  50. (tags "@work/NEXT")
  51. (tags "@home/NEXT")
  52. (tags "@night/NEXT")
  53. (tags "@selectp/NEXT")))
  54. ("R" "Weekly Review"
  55. ((agenda "" ((org-agenda-span 7)))
  56. (stuck "") ; review stuck projects as designated by org-stuck-projects
  57. (tags "PROJECT/-DONE-MAYBE") ; review all projects
  58. (todo "MAYBE") ; review someday/maybe items
  59. (todo "WAITING")))) ; review waiting items
  60. org-use-tag-inheritance nil ; bug in variable below, just turn 'em off
  61. org-tags-exclude-from-inheritance '("PROJECT" "SPRINT") ; PROJECT should not be inheritable
  62. org-stuck-projects
  63. '("+PROJECT/-MAYBE-DONE" ("TODO" "NEXT") nil "\\<IGNORE\\>")
  64. org-tag-alist '(("PROJECT" . ?p)
  65. ("@home" . ?h)
  66. ("@night" . ?n)
  67. ("@selectp" . ?s)
  68. ("@errand" . ?e)
  69. ("@read" . ?r)
  70. ("@work" . ?w)
  71. ("@family" . ?f))
  72. org-modules '(org-drill
  73. org-clock
  74. org-id
  75. org-info
  76. org-habit
  77. org-protocol
  78. org-annotate-file
  79. org-eval
  80. org-expiry
  81. org-contacts
  82. org-man
  83. org-notmuch
  84. org-collector
  85. org-panel
  86. org-screen
  87. org-toc)
  88. ; refile targets
  89. org-refile-targets '(("~/org/todo.org" :maxlevel . 2)
  90. ("~/org/someday.org" :maxlevel . 2)
  91. ("~/org/town.org" :maxlevel . 2)
  92. ("~/org/personal.org" :maxlevel . 2)
  93. ("~/org/elation.org" :maxlevel . 2))))
  94. ;; org-match-sparse-tree
  95. ;;
  96. ;; org-set-tags-command
  97. (defun +open-todo-file ()
  98. (interactive)
  99. "Opens the todo file"
  100. (find-file +todo-file))
  101. (map!
  102. :leader
  103. :desc "Open inbox" "I" #'+open-todo-file)
  104. (defun +show-agenda ()
  105. (interactive)
  106. (delete-other-windows)
  107. (with-popup-rules! nil
  108. (org-agenda-list)
  109. (calendar))
  110. (other-window 1)
  111. (split-window-vertically)
  112. (other-window 1)
  113. (find-file +todo-file))
  114. (map! :leader
  115. (:prefix "a"
  116. :desc "Org Agenda" "o" #'org-agenda
  117. :desc "Org open link" "l" #'org-open-at-point
  118. :desc "Sync gcal with org" "g" #'org-gcal-sync
  119. :desc "Set task deadline" "d" #'org-deadline
  120. :desc "Schedule task" "s" #'org-schedule
  121. :desc "New journal entry" "j" #'org-journal-new-entry
  122. :desc "Org set property" "p" #'org-set-progerty
  123. :desc "Save all org buffers" "a" #'org-save-all-org-buffers
  124. :desc "Org todo" "t" #'org-todo
  125. :desc "Org set tags" "T" #'org-set-tags-command))