dotfiles/.emacs.d/org/org.org
2020-11-25 08:32:51 +01:00

2.1 KiB

ORG

Org Roam

  (use-package org-roam
    :straight t
    :config
    (setq org-roam-directory "~/org")
    (add-hook 'after-init-hook 'org-roam-mode))

Org Agenda

  (setq org-agenda-files '("~/org" "~/org/school"))
  (add-hook 'org-mode-hook (lambda ()
			     (set-fill-column 120)
			     (display-fill-column-indicator-mode)))

  (setq org-agenda-custom-commands
	'(("h" "Agenda and Home-related tasks"
	   ((agenda "")
	    (tags-todo "home")
	    (tags "garden")))
	  ("o" "Agenda and Office-related tasks"
	   ((agenda "")
	    (tags-todo "work")
	    (tags "office")))
	  ("i" "Agenda and School-related tasks"
	   ((agenda "")
	    (tags-todo "school")
	    (tags "school")))))

  (setq org-highest-priority ?A)
  (setq org-lowest-priority ?E)
  (setq org-default-priority ?B)

  (require 'org-alert)
  (require 'notifications)

ORG Linkz

Based on org-linkz. Remove validation link from exported html file

  (setq org-html-validation-link nil)
  (require 'org-protocol)
  (setq org-capture-templates
 '(
   ("o" "Link capture" entry
    (file+headline "~/org/linkz.org" "INBOX")
    "* %a %U"
    :immediate-finish t)
   ))
  (setq org-protocol-default-template-key "o")

Then a .desktop file is needed for Firefox/Chromium

  [Desktop Entry]
  Name=org-protocol
  Exec=emacsclient -n %u
  Type=Application
  Terminal=fale
  Categories=System;
  MimeType=x-scheme-handler/org-protocol;

Then a bookmark must be added into firefox with this location

  javascript:location.href="org-protocol:///capture?url="+encodeURIComponent(location.href)+"&title="+encodeURIComponent(document.title||"[untitled page]")