Skip to content

Commit

Permalink
feat: separate org configuration ... [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
AfsmNGhr committed Jun 28, 2018
1 parent 4b731e7 commit f73e59a
Showing 1 changed file with 93 additions and 69 deletions.
162 changes: 93 additions & 69 deletions init.org
Original file line number Diff line number Diff line change
Expand Up @@ -1142,10 +1142,10 @@ Run =org= task.
(org-todo org-clock-in-switch-to-state))
#+end_src

More =org=.
Main =org=.

#+begin_src elisp
(use-package org :defer t :pin melpa
(use-package org :defer 30 :pin melpa
:init
(defconst afsmnghr/org-dir (getenv "ORG_PATH"))

Expand All @@ -1157,74 +1157,98 @@ More =org=.
org-todo-keywords
'((sequence "TODO(t!)" "NEXT(n@/!)" "INPROGRESS(i!)" "HOLD(h@/!)"
"DONE(d!)" "CANCELLED(c@/!)")))
:bind
(:map global-map ("C-c a" . org-agenda)))
#+end_src

(use-package org-faces :ensure f
:init
(setq org-todo-keyword-faces
'(("INPROGRESS" :foreground "DodgerBlue2" :weight bold)
("HOLD" :foreground "firebrick2" :weight bold)
("NEXT" :foreground "OrangeRed2" :weight bold))
org-priority-faces '((?A . (:foreground "firebrick2" :weight 'bold))
(?B . (:foreground "OrangeRed2"))
(?C . (:foreground "DodgerBlue2")))))

(use-package org-src :ensure f
:init
(setq org-src-fontify-natively t
org-edit-src-content-indentation 2
org-src-tab-acts-natively t
org-src-preserve-indentation t
org-src-window-setup 'current-window
org-src-ask-before-returning-to-edit-buffer nil))

(use-package org-agenda :ensure f
:config
(setq org-agenda-files (list afsmnghr/org-dir (concat
afsmnghr/org-dir "orgzly"))
org-agenda-start-on-weekday 1
org-agenda-dim-blocked-tasks nil
org-agenda-compact-blocks t
org-agenda-skip-scheduled-if-done nil
org-agenda-clockreport-parameter-plist
(quote (:link t :maxlevel 5 :fileskip0 t :compact t :narrow 80)))
:bind
(:map global-map ("C-c a" . org-agenda)))

(use-package org-protocol :ensure f :defer t
:init
(setq org-protocol-default-template-key "L"))
Org colors.

(use-package org-capture :ensure f :defer t
:init
(defconst afsmnghr/org-capture-templates
'(("L" "Links" entry (file+datetree (concat afsmnghr/org-dir "links.org"))
"* %c :LINK:\n%U %?%:initial")
("d" "Diary" entry (file+datetree (concat afsmnghr/org-dir "diary.org"))
"* %?\n%U\n" :clock-in t :clock-resume t)
("w" "Work" entry (file+datetree (concat afsmnghr/org-dir "work.org"))
"* TODO %? :WORK:\n%U\n" :clock-in t :clock-resume t)))
(setq org-capture-templates afsmnghr/org-capture-templates)
:bind
(:map global-map ("C-c c" . org-capture)))

(use-package org-clock :ensure f :defer t
:init
(setq org-clock-history-length 30
org-clock-in-switch-to-state "INPROGRESS"
org-clock-continuously t
org-clock-in-resume t
org-clock-into-drawer t
org-clock-out-remove-zero-time-clocks t
org-clock-out-when-done t
org-clock-persist 'history
org-clock-auto-clock-resolution (quote when-no-clock-is-running))
org-clock-clocked-in-display 'mode-line
org-clock-persist-query-resume nil
org-clock-report-include-clocking-task t)
(org-clock-persistence-insinuate))

:commands org-agenda
#+begin_src elisp
(use-package org-faces :ensure f
:after org
:init
(setq org-todo-keyword-faces
'(("INPROGRESS" :foreground "DodgerBlue2" :weight bold)
("HOLD" :foreground "firebrick2" :weight bold)
("NEXT" :foreground "OrangeRed2" :weight bold))
org-priority-faces '((?A . (:foreground "firebrick2" :weight 'bold))
(?B . (:foreground "OrangeRed2"))
(?C . (:foreground "DodgerBlue2")))))
#+end_src

Org blocks.

#+begin_src elisp
(use-package org-src :ensure f
:after org
:init
(setq org-src-fontify-natively t
org-edit-src-content-indentation 2
org-src-tab-acts-natively t
org-src-preserve-indentation t
org-src-window-setup 'current-window
org-src-ask-before-returning-to-edit-buffer nil))
#+end_src

Org agenda.

#+begin_src elisp
(use-package org-agenda :ensure f
:after org
:config
(setq org-agenda-files (list afsmnghr/org-dir (concat
afsmnghr/org-dir "orgzly"))
org-agenda-start-on-weekday 1
org-agenda-dim-blocked-tasks nil
org-agenda-compact-blocks t
org-agenda-skip-scheduled-if-done nil
org-agenda-clockreport-parameter-plist
(quote (:link t :maxlevel 5 :fileskip0 t :compact t :narrow 80))))
#+end_src

Org protocol.

#+begin_src elisp
(use-package org-protocol :ensure f :defer t
:after org
:init
(setq org-protocol-default-template-key "L"))
#+end_src

Org capture.

#+begin_src elisp
(use-package org-capture :ensure f :defer t
:after org
:init
(defconst afsmnghr/org-capture-templates
'(("L" "Links" entry (file+datetree (concat afsmnghr/org-dir "links.org"))
"* %c :LINK:\n%U %?%:initial")
("d" "Diary" entry (file+datetree (concat afsmnghr/org-dir "diary.org"))
"* %?\n%U\n" :clock-in t :clock-resume t)
("w" "Work" entry (file+datetree (concat afsmnghr/org-dir "work.org"))
"* TODO %? :WORK:\n%U\n" :clock-in t :clock-resume t)))
(setq org-capture-templates afsmnghr/org-capture-templates)
:bind
(:map global-map
("C-c l" . org-store-link)))
(:map global-map ("C-c c" . org-capture)))
#+end_src

Org clock.

#+begin_src elisp
(use-package org-clock :ensure f :defer t
:after org
:init
(setq org-clock-history-length 30
org-clock-in-switch-to-state "INPROGRESS"
org-clock-continuously t
org-clock-in-resume t
org-clock-into-drawer t
org-clock-out-remove-zero-time-clocks t
org-clock-out-when-done t
org-clock-persist 'history
org-clock-clocked-in-display 'mode-line
org-clock-persist-query-resume nil
org-clock-report-include-clocking-task t)
(org-clock-persistence-insinuate))
#+end_src

0 comments on commit f73e59a

Please sign in to comment.