This package is no longer maintained. If you have an issue or pull request, please send it to https://github.com/FelipeLema/emacs-counsel-gtags
GNU GLOBAL interface of ivy.
- Basic commands
- find file command
- Tag command
- Context command(dwim)
- Find definition and references
- include header support
-
GTAGSLIBPATH
support - Basic History command
- History navigate command
- Tramp support
- Windows support
- Emacs 24.3 or higher versions
- counsel
- GNU global 6.2.3 or higher versions
counsel-gtags
is available on MELPA and MELPA stable
You can install counsel-gtags
with the following command.
M-x package-install [RET] counsel-gtags [RET]
You can search for tags or files in the database. Every time you jump to a
definition, reference or symbol the current position is pushed to the context
stack. You can navigate backward and forward within this stack with
counsel-gtags-go-backward
and counsel-gtags-go-forward
.
Search for definition.
Search for references.
Search for symbol references.
Search for file among tagged files.
Go to previous position in context stack.
Go to next position in context stack.
Create GNU GLOBAL tags.
Update tags.
Find name by context.
- Jump to tag definition if cursor is on tag reference
- Jump to tag reference if cursor is on tag definition
(add-hook 'c-mode-hook 'counsel-gtags-mode)
(add-hook 'c++-mode-hook 'counsel-gtags-mode)
(with-eval-after-load 'counsel-gtags
(define-key counsel-gtags-mode-map (kbd "M-t") 'counsel-gtags-find-definition)
(define-key counsel-gtags-mode-map (kbd "M-r") 'counsel-gtags-find-reference)
(define-key counsel-gtags-mode-map (kbd "M-s") 'counsel-gtags-find-symbol)
(define-key counsel-gtags-mode-map (kbd "M-,") 'counsel-gtags-go-backward))