doomemacs/modules/tools/gist/config.el
Henrik Lissner 3c6f48f9ec
Move evil & corrective keybinds to respective modules
Keybinds that correct behavior or provide or extend vim functionality
were moved to their respective modules, or to the :editor evil module.

Keybinds in the global space, that are particularly opinionated but
potentially harmful or imposing as a default, or likely for users to
change (like leader keys), are kept in config/default.
2019-10-26 23:44:28 -04:00

29 lines
924 B
EmacsLisp

;;; tools/gist/config.el -*- lexical-binding: t; -*-
;; NOTE On occasion, the cache gets corrupted, causing wrong-type-argument
;; errors. If that happens, try `+gist/kill-cache'. You may have to restart
;; Emacs.
(after! gist
(set-evil-initial-state! 'gist-list-mode 'normal)
(set-popup-rule! "^\\*gist-" :ignore t)
(defadvice! +gist--open-in-popup-a (orig-fn &rest args)
:around #'gist-list-render
(funcall orig-fn (car args) t)
(unless (cadr args)
(pop-to-buffer (current-buffer))))
(map! :map gist-list-menu-mode-map
:n "go" #'gist-browse-current-url
:n "gr" #'gist-list-reload
:n "c" #'gist-add-buffer
:n "d" #'gist-kill-current
:n "e" #'gist-edit-current-description
:n "f" #'gist-fork
:n "q" #'kill-current-buffer
:n "s" #'gist-star
:n "S" #'gist-unstar
:n "y" #'gist-print-current-url))