2021-12-15 14:14:10 +01:00
( use-package org
2021-12-17 19:23:22 +01:00
:ensure nil
:hook ( org-mode . turn-on-auto-fill )
:init ( org-clock-persistence-insinuate )
:bind
( ( " C-c l " . org-store-link )
( " C-c a " . org-agenda )
( " C-c c " . org-capture )
( " C-c b " . org-switchb ) )
2021-12-15 14:14:10 +01:00
:init
( org-babel-lob-ingest " ~/.emacs.d/library-of-babel.org " )
2022-11-19 15:03:23 +01:00
( setq org-capture-templates ' ( ) )
2021-12-15 14:14:10 +01:00
:custom
2022-01-24 09:01:40 +01:00
( org-hide-emphasis-markers nil )
2021-12-15 14:14:10 +01:00
( org-default-notes-file " notes.org " )
( org-insert-mode-line-in-empty-file t )
( org-adapt-indentation nil )
( org-agenda-prefix-format
' ( ( agenda . " %i %-12:c%?-12t%-6e% s " )
( todo . " %i %-12:c %-6e " )
( tags . " %i %-12:c " )
( search . " %i %-12:c " ) ) )
( org-agenda-dim-blocked-tasks nil )
( org-agenda-inhibit-startup nil )
2022-10-31 08:05:37 +01:00
( org-agenda-span 14 )
2021-12-15 14:14:10 +01:00
( org-agenda-start-on-weekday 1 )
( org-agenda-include-diary t )
( org-clock-out-remove-zero-time-clocks t )
( org-clock-persist t )
( org-clock-rounding-minutes 30 )
( org-confirm-babel-evaluate nil )
( org-duration-format ( quote h:mm ) )
( org-export-with-sub-superscripts nil )
( org-export-dispatch-use-expert-ui nil )
2022-11-20 10:33:24 +01:00
( org-export-backends ' ( ascii html latex md ) )
( org-global-properties ' ( ( " EFFORT_ALL " . " 0:30 1:00 2:00 3:00 5:00 8:00 " ) ) )
2021-12-15 14:14:10 +01:00
( org-html-doctype " html5 " )
( org-html-html5-fancy t )
2022-11-20 10:33:24 +01:00
( org-latex-pdf-process ' ( " latexmk -xelatex -shell-escape -quiet -f %f " ) )
2021-12-15 14:14:10 +01:00
( org-latex-compiler " xelatex " )
( org-latex-listings t )
( org-log-done ( quote time ) )
( org-refile-targets ' ( ( nil :maxlevel . 3 ) ) )
( org-startup-folded t )
( org-startup-truncated nil )
( org-src-fontify-natively t )
( org-src-tab-acts-natively t )
( org-src-window-setup 'other-window )
( org-time-stamp-rounding-minutes ' ( 30 30 ) )
( org-todo-keywords
2022-02-21 08:54:02 +01:00
' ( ( sequence " TODO " " DOING(!) " " DONE(!) " )
2022-05-06 20:28:37 +02:00
( sequence " RECRUIT " " INTERVIEW " " QDA " " DOC " " REVIEW " ) ) )
2021-12-15 14:14:10 +01:00
( org-use-property-inheritance nil )
:config
2022-04-29 14:41:36 +02:00
( when ( eq system-type 'windows-nt )
( setq org-babel-sqlite3-command " c:/msys64/mingw64/bin/sqlite3.exe " ) )
2021-12-15 14:14:10 +01:00
( org-babel-do-load-languages
'org-babel-load-languages
2022-08-12 21:04:13 +02:00
' ( ( emacs-lisp . t ) ( lisp . t ) ( gnuplot . t ) ( python . t ) ( sqlite . t ) ( shell . t ) ( plantuml . t ) ) )
2022-05-06 19:31:15 +02:00
;; work with org-agenda dispatcher [c] "Today Clocked Tasks" to view today's clocked tasks.
( defun org-agenda-log-mode-colorize-block ( )
" Set different line spacing based on clock time duration. "
( save-excursion
( let* ( ( colors ( cl-case ( alist-get 'background-mode ( frame-parameters ) )
( 'light ( list " #d8dee9 " " #e5e9f0 " " #eceff4 " ) )
( 'dark ( list " #bf616a " " #d08770 " " #ebcb8b " " #a3be8c " " #b48ead " ) ) ) )
pos
duration )
( nconc colors colors )
( goto-char ( point-min ) )
( while ( setq pos ( next-single-property-change ( point ) 'duration ) )
( goto-char pos )
( when ( and ( not ( equal pos ( point-at-eol ) ) )
( setq duration ( org-get-at-bol 'duration ) ) )
;; larger duration bar height
( let ( ( line-height ( if ( < duration 15 ) 1.0 ( + 0.5 ( / duration 30 ) ) ) )
( ov ( make-overlay ( point-at-bol ) ( 1+ ( point-at-eol ) ) ) ) )
( overlay-put ov 'face ` ( :background , ( car colors ) :foreground " black " ) )
( setq colors ( cdr colors ) )
( overlay-put ov 'line-height line-height )
( overlay-put ov 'line-spacing ( 1- line-height ) ) ) ) ) ) ) )
( add-hook 'org-agenda-finalize-hook #' org-agenda-log-mode-colorize-block ) )
2022-11-19 15:03:23 +01:00
;; Just make a note
( add-to-list 'org-capture-templates ' ( " n " " Note " entry ( file+headline " notes.org " " Notes " ) " * %k \n %U \n - %l \n - %K \n %i \n %? " ) )
;; Task driven life
( add-to-list 'org-capture-templates ' ( " t " " Task " entry ( file+headline " planning.org " " Tasks " ) " * TODO %? \n %u " ) )
;; Recurring appointments
( add-to-list 'org-capture-templates ' ( " a " " Appointment " entry ( file+headline " planning.org " " Appointments " ) " * %? \n %T \n " ) )
;; Capture a meeting
( add-to-list 'org-capture-templates ' ( " m " " Meeting " entry ( file+headline " planning.org " " Meetings " ) " * %? :MEETING: \n %T " :clock-in t ) )
;; Capture a training
( add-to-list 'org-capture-templates ' ( " w " " Training " entry ( file+headline " planning.org " " Trainings " ) " * %? :TRAINING: \n %T " :clock-in t ) )
;; Log my activities
2022-12-08 18:41:45 +01:00
( add-to-list 'org-capture-templates ' ( " j " " Journal " entry ( file+olp+datetree " journal.org " " Journal " ) " * %^{Activity} \n Entered on %T \n %? " :tree-type week :empty-lines-after 1 ) )
2022-11-19 15:03:23 +01:00
;; Log my activities
2022-12-08 20:16:03 +01:00
( add-to-list 'org-capture-templates ' ( " l " " Log " entry ( file+olp+datetree " journal.org " " Logbook " ) " * %U - %^{Activity} :LOG: \n %? " :empty-lines-after 1 ) )
2022-11-19 15:03:23 +01:00
;; Log my growth talks
( add-to-list 'org-capture-templates ' ( " g " " Growth Talk " entry ( file+olp+datetree " growthtalk.org " " Talks " ) " * %U - %^{Activity} :TALK: " ) )
;; Record general hours
( add-to-list 'org-capture-templates ' ( " A " " Allgemein " table-line ( file+olp " journal.org " " Stunden " " Allgemein " ) " | %u | %^{Stunden} | %? | " ) )
;; Maintain a shopping wish list
( add-to-list 'org-capture-templates ' ( " B " " Buy " table-line ( file+olp " journal.org " " Shopping " ) " | %u | %^{Preis} | %? | " ) )
2022-05-06 19:31:15 +02:00
( use-package org-roam
:after org
:init
( setq org-roam-v2-ack t )
( setq org-roam-db-location " ~/org-roam.db " )
( require 'org-roam-dailies )
:bind ( ( " C-c r l " . org-roam-buffer-toggle )
( " C-c r f " . org-roam-node-find )
( " C-c r g " . org-roam-graph )
( " C-c r i " . org-roam-node-insert )
( " C-c r c " . org-roam-capture )
( " C-c r j " . org-roam-dailies-map )
:map org-roam-dailies-map
( " t " . org-roam-dailies-capture-today )
( " y " . org-roam-dailies-capture-yesterday )
( " T " . org-roam-dailies-capture-tomorrow )
:map org-mode-map
2022-05-06 20:28:37 +02:00
( " C-M-i " . completion-at-point ) )
:custom
( org-roam-completion-everywhere t )
( org-roam-dailies-capture-templates
' ( ( " d " " default " entry " * %<%R> %? "
:if-new ( file+head " %<%F>.org " " #+title: %<%F> \n " ) ) ) )
( org-roam-capture-templates
' ( ( " d " " default " plain
" %? "
:if-new ( file+head " %<%Y%m%d%H%M%S>-${slug}.org " " #+title: ${title} \n #+date: %U \n " )
:unnarrowed t )
( " n " " Note " plain
" %? "
:if-new ( file+head " %<%Y%m%d%H%M%S>-${slug}.org " " #+title: ${title} \n #+date: %U \n %l \n \n %i " )
:unnarrowed t )
( " p " " personas " plain
" %? "
:if-new ( file+head " %<%Y%m%d%H%M%S>-${slug}.org " " #+title: ${title} \n #+date: %U \n * Personality \n * Behaviors \n * Needs & Goals \n " )
:unnarrowed t ) ) ) )
2021-12-15 17:29:07 +01:00
2021-12-15 17:32:59 +01:00
( use-package org-tree-slide
2021-12-17 16:29:49 +01:00
:bind ( " <f5> " . org-tree-slide-mode )
2021-12-15 17:32:59 +01:00
:custom
( org-image-actual-width nil ) )
2021-12-15 17:40:15 +01:00
( use-package org-web-tools
2022-05-06 19:31:15 +02:00
:defer t
2021-12-15 17:40:15 +01:00
:custom ( org-web-tools-pandoc-sleep-time 0.4 ) )
2022-05-06 20:28:37 +02:00
;; (use-package ob-go
;; :after org)
2022-05-06 19:31:15 +02:00
( use-package ox-reveal
:after org )
;; (defun me/write-readme-md-on-save ()
;; ;; when README.org, also write README.md on save
;; (when (string-match "README" (buffer-file-name))
;; (make-local-variable 'after-save-hook)
;; (add-hook 'after-save-hook
;; (lambda () (let ((outfile (org-export-output-file-name ".md")))
;; (org-export-to-file 'md outfile))))))
2022-01-13 20:01:00 +01:00
;; (add-hook 'org-mode-hook 'me/write-readme-md-on-save)
2022-08-12 21:04:13 +02:00
( use-package ob-go
:after org
:config
( append ' ( ( go . t ) ) org-babel-load-languages ) )
( use-package ob-http
:after org
:config
( append ' ( ( http . t ) ) org-babel-load-languages ) )
;; (use-package ob-racket
;; :after org
;; :pin manual
;; :config
;; (append '((racket . t) (scribble . t)) org-babel-load-languages))