General refactor, cleanup & commenting
This commit is contained in:
parent
8707a80c2b
commit
e265431507
12 changed files with 251 additions and 241 deletions
|
@ -4,10 +4,13 @@
|
|||
(defun +gist/open-current ()
|
||||
(interactive)
|
||||
(gist-fetch-current)
|
||||
(doom/popup-close-all))
|
||||
(when-let (win (get-buffer-window "*github:gists*"))
|
||||
(doom/popup-close win)))
|
||||
|
||||
;;;###autoload
|
||||
(defun +gist/kill-cache ()
|
||||
"Clears the gist cache. Necessary when a faulty cache causes gist.el to be
|
||||
entirely unuseable."
|
||||
(interactive)
|
||||
(delete-directory (expand-file-name "gh" pcache-directory) t)
|
||||
(message "gist.el cache cleared"))
|
||||
|
|
|
@ -14,16 +14,16 @@
|
|||
;; evil-ify gist listing
|
||||
(set! :evil-state 'gist-list-mode 'normal)
|
||||
(map! :map gist-list-menu-mode-map
|
||||
:n "RET" '+gist/open-current
|
||||
:n "d" 'gist-kill-current
|
||||
:n "r" 'gist-list-reload
|
||||
:n "c" 'gist-add-buffer
|
||||
:n "y" 'gist-print-current-url
|
||||
:n "b" 'gist-browse-current-url
|
||||
:n "s" 'gist-star
|
||||
:n "S" 'gist-unstar
|
||||
:n "f" 'gist-fork
|
||||
:n "q" 'quit-window)
|
||||
:n "RET" #'+gist/open-current
|
||||
:n "d" #'gist-kill-current
|
||||
:n "r" #'gist-list-reload
|
||||
:n "c" #'gist-add-buffer
|
||||
:n "y" #'gist-print-current-url
|
||||
:n "b" #'gist-browse-current-url
|
||||
:n "s" #'gist-star
|
||||
:n "S" #'gist-unstar
|
||||
:n "f" #'gist-fork
|
||||
:n "q" #'quit-window)
|
||||
|
||||
(when (bound-and-true-p shackle-mode)
|
||||
(defun +gist*list-render (orig-fn &rest args)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue