diff options
author | Raúl Benencia <id@rbenencia.name> | 2024-09-29 16:20:17 -0700 |
---|---|---|
committer | Raúl Benencia <id@rbenencia.name> | 2024-09-29 16:20:47 -0700 |
commit | d4b1077b6d85b69c31abea7c8802d2adda85cdc2 (patch) | |
tree | 44acfe14914eb4c1e97a1a3f1f5098cdecabd192 /.emacs.d/rul-lisp/packages | |
parent | 50da7ec169380b08407c08b0b620a0752f7f0660 (diff) |
emacs: update denote bindings and hooks
Diffstat (limited to '.emacs.d/rul-lisp/packages')
-rw-r--r-- | .emacs.d/rul-lisp/packages/rul-write.el | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/.emacs.d/rul-lisp/packages/rul-write.el b/.emacs.d/rul-lisp/packages/rul-write.el index 16eae84..b997ed9 100644 --- a/.emacs.d/rul-lisp/packages/rul-write.el +++ b/.emacs.d/rul-lisp/packages/rul-write.el @@ -7,7 +7,14 @@ (use-package denote :ensure t + :hook (dired-mode . denote-dired-mode) + :bind + (("C-c n n" . denote) + ("C-c n r" . denote-rename-file) + ("C-c n l" . denote-link) + ("C-c n b" . denote-backlinks)) :config + (denote-rename-buffer-mode 1) (setq denote-infer-keywords t) (setq denote-sort-keywords t) (setq denote-file-type 'org) @@ -16,16 +23,14 @@ (setq denote-link-fontify-backlinks t) (setq denote-rename-no-confirm t) - (add-hook 'find-file-hook #'denote-link-buttonize-buffer) - (add-hook 'dired-mode-hook #'denote-dired-mode-in-directories) - (let ((map global-map)) (define-key map (kbd "C-c n j") #'rul/denote-journal) (define-key map (kbd "C-c n n") #'denote) (define-key map (kbd "C-c n f") #'denote-open-or-create) (define-key map (kbd "C-c n i") #'denote-link) (define-key map (kbd "C-c n r") #'denote-rename-file) - )) + ) +) (defun rul/denote-journal () "Create an entry tagged 'journal' with the date as its title. |