blob: c6e6d045847e517e9653d3ef2076daec295fac39 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
|
;; -*- lexical-binding: t; -*-
(defvar-local agenda-file "~/Personal/roam/agenda/agenda_tasks.org")
(defun bd/org-mode-setup-hook ()
"Sets up improved org-mode defaults upon
each org file open."
(org-indent-mode)
(org-toggle-inline-images)
(org-toggle-pretty-entities))
;; hooks
(add-hook 'org-mode-hook 'bd/org-mode-setup-hook)
;; binds
(keymap-global-set "C-c n a" 'org-agenda)
(keymap-global-set "C-c n c" 'org-capture)
(keymap-global-set "C-c n s" 'org-schedule)
(keymap-global-set "C-c n d" 'org-deadline)
(keymap-global-set "C-c n r" 'org-refile)
;; source blocks
(org-babel-do-load-languages
'org-babel-load-languages
'((emacs-lisp . t)
(python . t)
(shell . t)
(lisp . t)))
;; standard
(setopt org-startup-folded 'show2levels
org-ellipsis " ▾")
;; agenda
(advice-add 'org-refile :after 'org-save-all-org-buffers) ; after refiling tasks, save all buffers
(setopt org-agenda-files
`(,agenda-file "~/Personal/roam/agenda/archived_tasks.org")
org-deadline-warning-days 7
org-log-done 'time
org-log-into-drawer "history"
org-todo-keywords
'((sequence "TODO(t)" "NEXT(n!)" "HOLD(h!)" "|" "DONE(d)" "CANC(c)"))
org-refile-targets ; refile into the headings of these files, not tags
'(("archived_tasks.org" :maxlevel . 1)
("agenda_tasks.org" :maxlevel . 1))
org-capture-templates
`(("c" " College")
("cs" "Software Testing" entry (file+olp ,agenda-file "CS415")
"* TODO %?\n DEADLINE: %^t")
("cm" "Machine Learning" entry (file+olp ,agenda-file "CS445")
"* TODO %?\n DEADLINE: %^t")
("cp" "Programming Languages" entry (file+olp ,agenda-file "CS454")
"* TODO %?\n DEADLINE: %^t")
("cc" "Creative Writing" entry (file+olp ,agenda-file "E210")
"* TODO %?\n DEADLINE: %^t")
("s" " Self")
("si" "Idea" entry (file+olp ,agenda-file "Idea / Return")
"* TODO %?\n %t")
("sc" "Context" entry (file+olp ,agenda-file "Idea / Return")
"* TODO %?\n %a")
("st" "Deadline" entry (file+olp ,agenda-file "Deadline")
"* TODO %?\n DEADLINE: %^t")
("sb" "Book" entry (file+olp ,agenda-file "Book List")
"* TODO %?\n %t"))
org-agenda-custom-commands
'(("S" "Standard Block Agenda"
((tags-todo "*"
((org-agenda-skip-function '(org-agenda-skip-if nil '(timestamp)))
(org-agenda-block-separator nil)
(org-agenda-overriding-header "Undated Tasks\n")))
(agenda "" ((org-agenda-span 8)
(org-deadline-warning-days 0)
(org-agenda-block-separator nil)
(org-scheduled-past-days 4)
(org-agenda-overriding-header "\nUpcoming Tasks\n")))
(agenda "" ((org-agenda-time-grid nil)
(org-agenda-show-all-dates nil)
(org-agenda-span 21)
(org-deadline-warning-days 0)
(org-agenda-block-separator nil)
(org-agenda-entry-types '(:deadline))
(org-agenda-skip-function '(org-agenda-skip-entry-if 'todo 'done))
(org-agenda-overriding-header "\nFuture Deadlines (+21d)\n"))))))
org-agenda-restore-windows-after-quit t)
(provide 'bd--org)
|