From 0bdf42650bafdad53e596619ce22090a28ff4df4 Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Wed, 21 Sep 2016 17:02:46 -0700 Subject: [PATCH] [Emacs] Improve helm-gtags --- dotfiles/emacs.d/README.org | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/dotfiles/emacs.d/README.org b/dotfiles/emacs.d/README.org index f0d6a232..8d6b4ec9 100644 --- a/dotfiles/emacs.d/README.org +++ b/dotfiles/emacs.d/README.org @@ -3739,23 +3739,25 @@ I've disabled perspective because I just don't use it much. *** helm-gtags #+BEGIN_SRC emacs-lisp (use-package helm-gtags - :disabled t - :config (custom-set-variables - '(helm-gtags-path-style 'relative) - '(helm-gtags-ignore-case t) - '(helm-gtags-auto-update t)) - :bind - (("M-t" . helm-gtags-find-tag) - ("M-r" . helm-gtags-find-rtag) - ("M-s" . helm-gtags-find-symbol) - ("C-c <" . helm-gtags-previous-history) - ("C-c >" . helm-gtags-next-history)) - :init + :config (progn - ;;; Enable helm-gtags-mode - (add-hook 'c-mode-hook 'helm-gtags-mode) - (add-hook 'c++-mode-hook 'helm-gtags-mode) - (add-hook 'asm-mode-hook 'helm-gtags-mode))) + (setq helm-gtags-ignore-case t + helm-gtags-auto-update t + helm-gtags-use-input-at-cursor t + helm-gtags-pulse-at-cursor t + helm-gtags-prefix-key "\C-cg" + helm-gtags-suggested-key-mapping t) + (cl-loop for hook in '(dired-mode-hook eshell-mode-hook c-mode-hook + c++-mode-hook asm-mode-hook) + do (add-hook hook 'helm-gtags-mode))) + :bind (:map helm-gtags-mode-map + ("C-c g a" . helm-gtags-tags-in-this-function) + ("C-j" . helm-gtags-select) + ("M-." . helm-gtags-dwim) + ("M-," . helm-gtags-pop-stack) + ("C-c <" . helm-gtags-previous-history) + ("C-c >" . helm-gtags-next-history))) + #+END_SRC *** sgml-mode #+BEGIN_SRC emacs-lisp