Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save paullemmens/5c42605fadf58c2456fe5d01a4a6b3d5 to your computer and use it in GitHub Desktop.
Save paullemmens/5c42605fadf58c2456fe5d01a4a6b3d5 to your computer and use it in GitHub Desktop.
(use-package! todotxt
:commands (todotxt-mode)
:demand t
;; :mode implies :defer
:mode (("todo\\.txt" . todotxt-mode)
("done\\.txt" . todotxt-mode))
:config
(if IS-MAC
(setq todotxt-file "~/Dropbox/todo/todo.txt")
(setq todotxt-file "/c/XXXXXXX/Dropbox/todo/todo.txt")
)
;; :init
(map!
(:leader :desc "todo.txt"
(:prefix "m"
(:prefix ("t" . "todotxt")
:desc "Open todo.txt" "o" #'todotxt
:desc "Quit" "q" #'todotxt-bury
:desc "Add todo item" "a" #'todotxt-add-item-any-buffer))))
;; This should give a nice submenu for the todotxt mode.
(map!
(:localleader
(:map todotxt-mode-map
"l" #'todotxt-unhide-all
"i" #'todotxt-show-incomplete
"x" #'todotxt-complete-toggle
"N" #'todotxt-nuke-item
"a" #'todotxt-add-item-any-buffer
"q" #'todotxt-bury
"r" #'todotxt-add-priority
"p" #'todotxt-add-priority
"A" #'todotxt-archive
"e" #'todotxt-edit-item
"t" #'todotxt-tag-item
"d" #'todotxt-add-due-date
"/" #'todotxt-filter-for
"\\" #'todotxt-filter-out
"s" #'save-buffer
"u" #'todotxt-undo)))
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment