From eb6b8293e30d4d9f17906016621894cbe41f29a3 Mon Sep 17 00:00:00 2001 From: Jakob L. Kreuze Date: Sat, 12 Jan 2019 10:33:50 -0500 Subject: More global keybindings. --- jakob.org | 42 ++++++++++++++++++++++++++++++++---------- 1 file changed, 32 insertions(+), 10 deletions(-) (limited to 'jakob.org') diff --git a/jakob.org b/jakob.org index 736ded5..c48050c 100644 --- a/jakob.org +++ b/jakob.org @@ -883,8 +883,8 @@ to use my X windows across workspaces. "Global key bindings" in EXWM work essentially anywhere, including buffers that are currently in char mode. The bindings below should be fairly straightforward. I've taken this as an opportunity to incorporate windmove to my workflow, now -that I have ?\s at my disposal. The choice of keys for that was inspired by the -WASD movement typical of first-person shooter games. +that I have the super key at my disposal. The choice of keys for that was +inspired by the WASD movement typical of first-person shooter games. #+BEGIN_SRC elisp :init @@ -900,6 +900,9 @@ WASD movement typical of first-person shooter games. ([?\s-X] . (lambda () (interactive) (start-process "" nil "/usr/bin/slock"))) + (,(kbd "s-") . (lambda () + (interactive) + (start-process "" nil "/usr/bin/kitty"))) ;; Keys are offset such that corresponds to the 0th workspace. ,@(mapcar (lambda (i) @@ -1032,7 +1035,8 @@ Scale up embedded LaTeX so that I can actually read it. #+END_SRC Replace my [[Imenu]] binding with =org-goto=, as it allows me to select headings with -subheadings. +subheadings. Keybindings for working with my Org workflow from anywhere are also +here, because =use-package= doesn't like split =:bind= declarations. #+BEGIN_SRC elisp :init @@ -1040,7 +1044,10 @@ subheadings. (setq org-outline-path-complete-in-steps nil) :bind - (:map org-mode-map + (("C-c a" . (lambda () (interactive) (org-agenda nil "d"))) + ("C-c c" . (lambda () (interactive) (org-capture nil "c"))) + ("C-c t" . (lambda () (interactive) (org-capture nil "t"))) + :map org-mode-map ("C-c s" . org-goto))) #+END_SRC @@ -1048,21 +1055,36 @@ subheadings. Automatically open a buffer named =*Mind Dump*= to, well, save all of my thoughts. They're dated and saved in a directory so I can =ag= them. This is the -closest thing I will ever have to an =ag= inside my brain. +closest thing I will ever have to an implementation of =ag= for my thoughts. #+BEGIN_SRC elisp (defvar mind-dump-directory "~/Notes/Mind Dumps" "Where to store dated 'mind dump' files.") -(let* ((filename (concatenate 'string - (file-name-as-directory mind-dump-directory) - (format-time-string "%Y-%m-%d") - ".org")) - (buffer (find-file-noselect filename))) +(defun mind-dump-filename () + "Returns the path of today's 'mind dump' file." + (concatenate 'string + (file-name-as-directory mind-dump-directory) + (format-time-string "%Y-%m-%d") + ".org")) + +(let* ((buffer (find-file-noselect (mind-dump-filename)))) (set-buffer buffer) (rename-buffer "*Mind Dump*")) #+END_SRC +** Capture + +Low-friction of adding things to the day's "mind dump" and my GTD inbox. + +#+BEGIN_SRC elisp +(setq org-capture-templates + `(("c" "Thought" plain (file ,(mind-dump-filename)) + "%?\n") + ("t" "TODO" entry (file "~/Notes/GTD/Inbox.org") + "* TODO %?\n"))) +#+END_SRC + ** Agenda Rather convoluted agenda setup to show me: -- cgit v1.3