Browse Source

forgot some fixes

master
Marc Pohling 6 years ago
parent
commit
90e534ff98
1 changed files with 26 additions and 26 deletions
  1. 52
      config.org

52
config.org

@ -625,32 +625,32 @@ For a more detailed example [[https://github.com/sachac/.emacs.d/blob/83d21e4733
See the doc for speed keys by checking out the documentation for speed keys in Org mode. See the doc for speed keys by checking out the documentation for speed keys in Org mode.
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(setq org-use-speed-commands t) (setq org-use-speed-commands t)
(setq org-image-actual-width 550) (setq org-image-actual-width 550)
(setq org-highlight-latex-and-related '(latex script entities)) (setq org-highlight-latex-and-related '(latex script entities))
#+END_SRC
#+END_SRC
Hide emphasis markup (e.g. / ... / for italics, etc.) Hide emphasis markup (e.g. / ... / for italics, etc.)
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(setq org-hide-emphasis-markers t) (setq org-hide-emphasis-markers t)
#+END_SRC
#+END_SRC
Setting some environment paths Setting some environment paths
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(if (string-equal user-login-name "POH") (if (string-equal user-login-name "POH")
(progn (progn
(defvar PATH_ORG_FILES "p:/Eigene Dateien/Notizen/") (defvar PATH_ORG_FILES "p:/Eigene Dateien/Notizen/")
(defvar PATH_ORG_JOURNAL "p:/Eigene Dateien/Notizen/Journal/") (defvar PATH_ORG_JOURNAL "p:/Eigene Dateien/Notizen/Journal/")
(defvar PATH_START "p:/Eigene Dateien/Notizen/")) (defvar PATH_START "p:/Eigene Dateien/Notizen/"))
) )
#+END_SRC
#+END_SRC
Sort org agenda by deadline and priority Sort org agenda by deadline and priority
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(setq org-agenda-sorting-strategy (setq org-agenda-sorting-strategy
(quote (quote
((agenda deadline-up priority-down) ((agenda deadline-up priority-down)
@ -658,20 +658,20 @@ For a more detailed example [[https://github.com/sachac/.emacs.d/blob/83d21e4733
(tags priority-down category-keep) (tags priority-down category-keep)
(search category-keep))) (search category-keep)))
) )
#+END_SRC
#+END_SRC
Custom todo-keywords, depending on environment Custom todo-keywords, depending on environment
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(if (string-equal user-login-name "POH") (if (string-equal user-login-name "POH")
(setq org-todo-keywords (setq org-todo-keywords
'((sequence "OPEN" "TODO" "UNCLEAR" "|" "DONE" "IMPOSSIBLE"))) '((sequence "OPEN" "TODO" "UNCLEAR" "|" "DONE" "IMPOSSIBLE")))
) )
#+END_SRC
#+END_SRC
Set locations of some org files Set locations of some org files
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(if (string-equal user-login-name "POH") (if (string-equal user-login-name "POH")
(progn (progn
(setq org-default-notes-file (concat PATH_ORG_FILES "notes.org")) (setq org-default-notes-file (concat PATH_ORG_FILES "notes.org"))
@ -680,11 +680,11 @@ For a more detailed example [[https://github.com/sachac/.emacs.d/blob/83d21e4733
(concat PATH_ORG_FILES "todo.org")))) (concat PATH_ORG_FILES "todo.org"))))
) )
(setq org-id-locations-file (concat PATH_USER_LOCAL ".org-id-locations")) (setq org-id-locations-file (concat PATH_USER_LOCAL ".org-id-locations"))
#+END_SRC
#+END_SRC
Work specific org-capture-templates Work specific org-capture-templates
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(if (string-equal user-login-name "POH") (if (string-equal user-login-name "POH")
(setq org-capture-templates (setq org-capture-templates
'(("t" "todo" entry (file (concat PATH_ORG_FILES "todo.org")) '(("t" "todo" entry (file (concat PATH_ORG_FILES "todo.org"))
@ -695,11 +695,11 @@ For a more detailed example [[https://github.com/sachac/.emacs.d/blob/83d21e4733
("u" "Unterbrechung" entry (file org-default-notes-file) ("u" "Unterbrechung" entry (file org-default-notes-file)
"* Unterbrechnung durch %? :Unterbrechung:\n%t" :clock-in t :clock-resume t))) "* Unterbrechnung durch %? :Unterbrechung:\n%t" :clock-in t :clock-resume t)))
) )
#+END_SRC
#+END_SRC
Customize the org agenda Customize the org agenda
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(defun my-org-skip-subtree-if-priority (priority) (defun my-org-skip-subtree-if-priority (priority)
"Skip an agenda subtree if it has a priority of PRIORITY. "Skip an agenda subtree if it has a priority of PRIORITY.
@ -725,19 +725,19 @@ For a more detailed example [[https://github.com/sachac/.emacs.d/blob/83d21e4733
(org-agenda-skip-if nil '(scheduled deadline)))) (org-agenda-skip-if nil '(scheduled deadline))))
(org-agenda-overriding-header "Sonstige Aufgaben:")))))) (org-agenda-overriding-header "Sonstige Aufgaben:"))))))
) )
#+END_SRC
#+END_SRC
** Org tags ** Org tags
The default value is -77, which is weird for smaller width windows. I'd rather have the tags align horizontally with the header. The default value is -77, which is weird for smaller width windows. I'd rather have the tags align horizontally with the header.
45 is a good column number to do that. 45 is a good column number to do that.
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(setq org-tags-column 45) (setq org-tags-column 45)
#+END_SRC
#+END_SRC
** Org babel languages ** Org babel languages
This code block is linux specific. Loading languages which aren't available seems to be a problem This code block is linux specific. Loading languages which aren't available seems to be a problem
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(cond ((eq system-type 'gnu/linux) (cond ((eq system-type 'gnu/linux)
(org-babel-do-load-languages (org-babel-do-load-languages
'org-babel-load-languages 'org-babel-load-languages
@ -759,9 +759,9 @@ For a more detailed example [[https://github.com/sachac/.emacs.d/blob/83d21e4733
) )
)) ))
) )
#+END_SRC
#+END_SRC
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(defun my-org-confirm-babel-evaluate (lang body) (defun my-org-confirm-babel-evaluate (lang body)
"Do not confirm evaluation for these languages." "Do not confirm evaluation for these languages."
(not (or (string= lang "beancount") (not (or (string= lang "beancount")
@ -773,30 +773,30 @@ For a more detailed example [[https://github.com/sachac/.emacs.d/blob/83d21e4733
(string= lang "R") (string= lang "R")
(string= lang "sqlite")))) (string= lang "sqlite"))))
(setq org-confirm-babel-evaluate 'my-org-confirm-babel-evaluate) (setq org-confirm-babel-evaluate 'my-org-confirm-babel-evaluate)
#+END_SRC
#+END_SRC
I want plots! I want plots!
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(use-package ess (use-package ess
:ensure t :ensure t
) )
(add-hook 'org-babel-after-execute-hook 'org-display-inline-images) (add-hook 'org-babel-after-execute-hook 'org-display-inline-images)
(add-hook 'org-mode-hook 'org-display-inline-images) (add-hook 'org-mode-hook 'org-display-inline-images)
#+END_SRC
#+END_SRC
** Org babel/source blocks ** Org babel/source blocks
I like to have source blocks properly syntax highlighted and with the editing popup window staying within the same window so all the windows don't jump around. Also, having the top and bottom trailing lines in the block is a waste of space, so we can remove them I like to have source blocks properly syntax highlighted and with the editing popup window staying within the same window so all the windows don't jump around. Also, having the top and bottom trailing lines in the block is a waste of space, so we can remove them
I noticed that fontification doesn't work with markdown mode when the block is indented after editing it in the org src buffer - the leading #s for headers don't get fontified properly because they apppear as Org comments. Setting ~org-src-preserve-identation~ makes things consistent as it doesn't pad source blocks with leading spaces I noticed that fontification doesn't work with markdown mode when the block is indented after editing it in the org src buffer - the leading #s for headers don't get fontified properly because they apppear as Org comments. Setting ~org-src-preserve-identation~ makes things consistent as it doesn't pad source blocks with leading spaces
#+BEGIN_SRC emacs-lisp
#+BEGIN_SRC emacs-lisp
(setq org-src-fontify-natively t (setq org-src-fontify-natively t
org-src-window-setup 'current-window org-src-window-setup 'current-window
org-src-strip-leading-and-trailing-blank-lines t org-src-strip-leading-and-trailing-blank-lines t
org-src-preserve-indentation nil ; these two lines respect the indentation of org-src-preserve-indentation nil ; these two lines respect the indentation of
org-edit-src-content-indentation 0 ; the surrounding text around the source block org-edit-src-content-indentation 0 ; the surrounding text around the source block
org-src-tab-acts-natively t) org-src-tab-acts-natively t)
#+END_SRC
#+END_SRC

Loading…
Cancel
Save