Remove unused Ex commands

This commit is contained in:
Henrik Lissner 2015-02-02 16:41:29 -05:00
parent 2793fce0ff
commit d42dacccc9
3 changed files with 0 additions and 55 deletions

View file

@ -207,8 +207,6 @@
file-name))
(progn ; ex-commands
(evil-ex-define-cmd "cycle" 'cycle-font)
(evil-ex-define-cmd "togglet[heme]" 'toggle-theme)
(evil-ex-define-cmd "full[scr]" 'toggle-frame-fullscreen)
(evil-ex-define-cmd "k[ill]" 'kill-this-buffer) ; Kill current buffer
(evil-ex-define-cmd "k[ill]o" 'my-cleanup-buffers) ; Kill current project buffers

View file

@ -1,45 +0,0 @@
(require 'helm)
(require 'helm-ag)
(defun helm-todo--candidate-transformer (candidate)
(when (string-match "\\`\\([^:]+\\):\\([^:]+\\):\\(.+\\)" candidate)
(format "%s %s %s"
(propertize (match-string 1 candidate) 'face 'helm-moccur-buffer)
(propertize "TODO" 'face 'helm-grep-lineno)
(helm-ag--highlight-candidate
(replace-regexp-in-string "^\\( *\\(/\\**\\|/+\\|[;#]+\\) *\\)+TODO ?" ""
(match-string 3 candidate))))))
(defvar helm-todo-source
'((name . "TODOs")
(init . helm-ag-init)
(candidates-in-buffer)
(persistent-action . helm-ag-persistent-action)
(real-to-display . helm-todo--candidate-transformer)
(action . (("Open file" . helm-ag--action-find-file)
("Open file other window" . helm-ag--action--find-file-other-window)))))
;;;###autoload (autoload 'my:helm-todo "helm-todo")
(evil-define-operator my:helm-todo (beg end &optional bang input)
:motion nil
:move-point nil
:type inclusive
:repeat nil
(interactive "<r><!><a>")
(let* ((helm-ag-default-directory (my--project-root bang))
(input (or input ""))
(helm-ag--last-input ""))
(helm-attrset 'search-this-file nil helm-ag-source)
(setq helm-ag--last-query
"ag --nogroup --nocolor --ignore '*.md' -- '(/\\*\\*?|//|[;#]) *TODO'")
(helm-attrset 'name
(format "TODOs in %s" helm-ag-default-directory)
helm-ag-source)
(helm :sources 'helm-todo-source
:buffer "*helm-ag*"
:input input
:prompt helm-global-prompt)))
(provide 'helm-todo)
;;; helm-todo.el ends here

View file

@ -31,14 +31,6 @@
(after "evil" (evil-ex-define-cmd "ref[actor]" 'emr-show-refactor-menu))))
;; todo's
(use-package hl-todo :init (add-hook 'find-file-hook 'hl-todo-mode))
(use-package helm-todo :commands my:helm-todo-search)
(evil-ex-define-cmd "todo" 'my:helm-todo)
;; (require 'evil-snipe)
;; (global-evil-snipe-mode 1)
(provide 'init-dev)
;;; init-dev.el ends here