Click here to Skip to main content
15,892,298 members
Articles / All Topics
Technical Blog

Exuberant Ctags and Notepad++ (or your preferred text editor) Perfect Together

Rate me:
Please Sign up or sign in to vote.
0.00/5 (No votes)
6 Nov 2013CPOL2 min read 13.7K  
Exuberant Ctags and Notepad++ (or your preferred text editor) perfect together
  • Working in a large code base?
  • Want to know the usage of a variable or a function, its location, its definition and a list of the locations of created instances?
  • Want it done quickly?

Exuberant Ctags and Notepad++ (or your preferred text editor) perfect together.

End of ad....

Much of the web work I've been doing at my day job I haven't really needed all the weight of a heavier IDE like Visual Studio 2010. Consequently, I've been using Notepad++ (because I'm posturing to eventually jump on the emacs and/or vim train and wanted to use some of the Unix environments tools).

Programmers from the days of old used the original ctags to mitigate the daunting task of maintaining large c code base of some pretty epic software predating the super powered (and at times super bloated) IDEs. It was written by the guy who wrote Rogue, curses, and contributed to the book The Art of Unix Programming, Ken Arnold. Now sporting over 40 (so that's 40 +1 really LOL) supported languages.

I know I'm late to the party but, better late than never. In particular, I have found ctags to be amazingly useful when dealing with PHP, vbscript, classic ASP and JavaScript. Languages that, by their very procedural nature, can cause a lot of spaghetti code, headaches and confusion. Maintainers of these types of projects I highly recommend it.

Exuberant Ctags Quick start (Windows)

The following directions are for the simplest of ctags configuration. You can most certainly dive more deeply into ctags to gain a grasp of all its raw power. (Mwwwaa!) But this certainly does the job if you want simple indexing.

  1. Download the executable from http://ctags.sourceforge.net/.
  2. Add it to global path
  3. Open up the command line
  4. Navigate to the folder root and run

    C:\sourcecodefolder\ctags.exe -R * 

    When executing that line, ctags will search all code in the current directory and recursively search all sub directories for supported files and add them to its index (tag) file. From there, you can use ctags to directly search the code or you could go the way of whatever text editor you are using. (See the links at the bottom for more resources.)

Useful Links for Exuberant Ctags

Note* For Mac Devs, if you don't have Macports, Homebrew, Fink or some package management solution, I would highly recommend one.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
CEO Hacker Ferret Software
United States United States
Owner at Hacker Ferret Software
Software Consultant with over 8 years in the trenches.

Specialized in .Net, javascript, and Android development. But adaptable enough for whatever you can dish out. I have a spiritual neck-beard just not a physical one.

For more info about me check out Hacker Ferret Software where we focus on hacking together your software with love.

We now offer a Free 30 Minute Consultation

Comments and Discussions

 
-- There are no messages in this forum --