[Emacs] Add ggtags setup

This commit is contained in:
Ivan Malison 2016-09-21 17:02:22 -07:00
parent 2600adcadd
commit 6a562d6398
No known key found for this signature in database
GPG Key ID: 62530EFBE99DC2F8

View File

@ -2352,6 +2352,27 @@ Intero seems to be causing hangs, so it has been disabled
:config :config
(add-to-list 'company-backend 'company-ghc)) (add-to-list 'company-backend 'company-ghc))
#+END_SRC #+END_SRC
**** C/C++
#+BEGIN_SRC emacs-lisp
(use-package cc-mode
:preface
(defun imalison:cc-mode-hook ()
(when (derived-mode-p 'c-mode 'c++-mode 'java-mode 'asm-mode)
(ggtags-mode 1)))
:config
(progn
(use-package ggtags
:demand t
:bind (:map ggtags-mode-map
("C-c g s" . ggtags-find-other-symbol)
("C-c g h" . ggtags-view-tag-history)
("C-c g r" . ggtags-find-reference)
("C-c g f" . ggtags-find-file)
("C-c g c" . ggtags-create-tags)
("C-c g u" . ggtags-update-tags)
("M-," . pop-tag-mark)))
(add-hook 'c-mode-common-hook 'imalison:cc-mode-hook)))
#+END_SRC
*** Data/Config/Protocol *** Data/Config/Protocol
**** thrift **** thrift
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp