I want to use evil mode with ggtags but evil mode keeps taking some of the bindings such as M-.
. I'm new to emacs and I'm interested in learning what's going on. At first I tried explicitly setting the load order by using a lambda like this:
(add-hook 'prog-mode-hook
'(lambda ()
(evil-local-mode)
(when (derived-mode-p 'c-mode 'c++-mode 'java-mode 'rust-mode)
(ggtags-mode 1))))
I then saw evil-overriding-maps
and evil-intercept-maps
but using them seemed to have no effect:
(add-to-list 'evil-overriding-maps '(ggtags-mode-map . nil) t)
(add-to-list 'evil-intercept-maps '(ggtags-mode-map . nil) t)
I realize that I could just explicitly bind to 'ggtags-find-tag-dwim
in one of the evil maps, but like I said I'm learning emacs and I'm wondering what's going on here and more importantly if there's a way to make it work without redoing all of the bindings that got clobbered. I figured using evil-overriding-maps
should do the trick but it doesn't seem to be. I did check the value of the variable with C-h v
and it did get added to that list.