Emacs code navigation? TAAAGS!

Emacs code navigation? TAAAGS!

Do you know when you open a code file and you want to navigate it but you have to fire up a whole enviroment just to do it? In clojure, would be cider, in python it would be elpy and so on…

Well, get ready feel free! All you need is a command line and vanilla emacs!!

The command is etags. What this command does is look for all the definitions you made in the files you pass as an argument with the language and it will create a TAGS file in the current directory.

find . -type f -name "*.clj" | xargs etags --language=lisp

Once that is done, use you xref-find-definitions and xref-pop-marker-stack command (alias in vanilla as M-. and M-,, respectively) and it will ask you where is the TAGS table.

You can reset the table with tags-reset-tags-table. If it feel very UNIX like, you would be right. It is! Enjoy!

Oh, not sure what languages are supported? Fear not!

etags --help

  1. emacs tags
  2. elpy
  3. cider

/comments ~lucasemmoreira/opinions@lists.sr.ht?Subject=Re: Emacs code navigation? TAAAGS!