How to configure ctags in Kate?
Solution 1:
Once you have CTags installed
sudo apt-get install exuberant-ctags
Activate the plugin by going to Settings -> Configure Kate...
Then when the window pops up, click Application -> Plugins and check "CTags"
Next in Kate's Index Targets tab pane, click Add and enter the /path/to/project/root
, then click Update Index
Now you will be able to use the CTags.
Notice the Database tab pane is where you can set the CTags command. See the man pages for options. Generally, I like to exclude my dependency package folders by adding:
--exclude=vendor --exclude=node_modules
No need to put anything in the "CTags Database File" field because Kate will automatically generate this file when you click Update Index
Note that you can, but do not need to create a .kateproject
file to use the CTags.
Solution 2:
First you need to make sure you have ctags installed:
sudo apt-get install exuberant-ctags
Create a ".kateproject" project file in the folder where your code is (see http://forum.kde.org/viewtopic.php?f=25&t=93570 for more info):
e.g. This the contents of one I set up recently:
{
"name": "Report Downloader"
, "files": [ { "directory": ".",
"filters": [
"*.php",
"*.css",
"*.js",
"*.html"
"*.py"
],
"recursive": 1 }
]
}
Then open a file within the project (you don't open the project directly) and ctags should start working.