A bunch of org mode stuff
This commit is contained in:
parent
2ffaa37381
commit
e33d0b58bc
3 changed files with 61 additions and 5 deletions
51
init.el
51
init.el
|
|
@ -10,7 +10,7 @@
|
|||
(setq visible-bell t)
|
||||
(setq warning-minimum-level :error)
|
||||
(global-visual-line-mode)
|
||||
|
||||
(setq initial-major-mode 'org-mode) ;; Scratch buffer is org mode
|
||||
;; Line Numbers
|
||||
(global-display-line-numbers-mode t)
|
||||
(column-number-mode)
|
||||
|
|
@ -113,19 +113,59 @@
|
|||
:ensure t)
|
||||
(use-package org-roam
|
||||
:ensure t
|
||||
:hook (org-mode . company-mode)
|
||||
:custom
|
||||
(org-roam-node-display-template
|
||||
(concat "${title:*} " (propertize "${tags:20}" 'face 'org-tag)))
|
||||
(org-roam-directory "/home/warwick/Sync/wiki/org/roam/")
|
||||
(org-roam-capture-templates
|
||||
'(("d" "default" plain "%?" :target
|
||||
(file+head "%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n#+date: %U\n")
|
||||
:unnarrowed t)
|
||||
("l" "literature" plain (file "~/.emacs.d/org-roam-templates/literature.org") :target
|
||||
(file+head "%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n#+date: %U\n#+filetags: :literature:\n")
|
||||
:unnarrowed t)
|
||||
("p" "project" plain (file "~/.emacs.d/org-roam-templates/project.org") :target
|
||||
(file+head "%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n#+date: %U\n#+filetags: :project:${title}:\n")
|
||||
:unnarrowed t)
|
||||
("f" "fleeting" plain "%?" :target
|
||||
(file+head "%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n#+date: %U\n#+filetags: :tofile:")
|
||||
:unnarrowed t)))
|
||||
:bind (("C-c n l" . org-roam-buffer-toggle)
|
||||
("C-c n f" . org-roam-node-find)
|
||||
("C-c n i" . org-roam-node-insert)
|
||||
("C-c n c" . org-roam-capture)
|
||||
("C-c n a" . org-roam-alias-add))
|
||||
("C-c n h" . org-idn-get-create)
|
||||
("C-c n a" . org-roam-alias-add)
|
||||
("C-c n t" . org-roam-tag-add))
|
||||
:bind-keymap
|
||||
("C-c n d" . org-roam-dailies-map)
|
||||
:config
|
||||
(org-roam-db-autosync-mode 1))
|
||||
(require 'org-roam-dailies) ;; ensure dailies keymap is available
|
||||
(require 'org-roam-export) ;; Ensure links are exported properly
|
||||
(org-roam-db-autosync-mode 1)
|
||||
(setq org-roam-completion-everywhere t))
|
||||
(use-package websocket
|
||||
:ensure t
|
||||
:after org-roam)
|
||||
(use-package org-roam-ui
|
||||
:ensure t
|
||||
:bind ("C-c n u" . org-roam-ui-mode)
|
||||
:after org-roam
|
||||
;; normally we'd recommend hooking orui after org-roam, but since org-roam does not have
|
||||
;; a hookable mode anymore, you're advised to pick something yourself
|
||||
;; if you don't care about startup time, use
|
||||
;; :hook (after-init . org-roam-ui-mode)
|
||||
:config
|
||||
(setq org-roam-ui-sync-theme t
|
||||
org-roam-ui-follow t
|
||||
org-roam-ui-update-on-save t
|
||||
org-roam-ui-open-on-start t))
|
||||
(use-package org-bullets
|
||||
:ensure t
|
||||
:after org
|
||||
:hook (org-mode . org-bullets-mode))
|
||||
(setq org-adapt-indentation t) ;; Set up correct indent on all org mode files
|
||||
;; TODO configure to be prettier
|
||||
|
||||
;; Tree Sitter (better syntax highlighting)
|
||||
|
|
@ -196,8 +236,9 @@
|
|||
'(package-selected-packages
|
||||
'(all-the-icons company-box counsel doom-modeline gruvbox-theme
|
||||
helpful ivy-rich lsp-ivy lsp-treemacs lsp-ui magit
|
||||
org-bullets org-roam projectile rainbow-delimiters
|
||||
tree-sitter-langs typescript-mode)))
|
||||
org-bullets org-roam org-roam-ui projectile
|
||||
rainbow-delimiters tree-sitter-langs
|
||||
typescript-mode)))
|
||||
(custom-set-faces
|
||||
;; custom-set-faces was added by Custom.
|
||||
;; If you edit it by hand, you could mess it up, so be careful.
|
||||
|
|
|
|||
7
org-roam-templates/literature.org
Normal file
7
org-roam-templates/literature.org
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
* Source
|
||||
Title: ${title}
|
||||
Author: %^{Author}
|
||||
Year: %^{Year}
|
||||
|
||||
* Notes
|
||||
%?
|
||||
8
org-roam-templates/project.org
Normal file
8
org-roam-templates/project.org
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
|
||||
* Description
|
||||
|
||||
* Notes
|
||||
|
||||
* Tasks
|
||||
** TODO fill out ${title}'s project node.
|
||||
** %?
|
||||
Loading…
Reference in a new issue