Yup, clj-kondo analysis data has everything I'd need. The row/col location of each var in each file and their name and doc is all there
And I maintain my own cache of it on a per-project basis in Emacs
Is there a way to configure it to just re-use the cache I already have? It's not a huge deal, but it'd be a bit nicer to only actually compute that data once
anakondo uses its own cache. the format in .clj-kondo/.cache is an implementation detail which is not supposed to be used by other tools since it can change (it doesn't change often, but it could happen)
That makes sense, it'd be nice if there was a canonical database of analysis data that other tools could hook into.
I think it's better if tools keep their own caches, caching is hard enough as it is
But it's likely that when you use anakondo to build up its cache, clj-kondo's cache will be populated as a side effect as well
I can also say that in practice, I've not seen any performance impact even on a 10 year old laptop that can't even run Google Chrome without crashing. The biggest issue for me right now is the initial time to analyse a project, and the fact that it blocks Emacs while doing that initial analysis. Most of the time there is taken by the Java analysis, not clj-kondo, so even then I don't think from clj-kondo's perspective its that big a problem for now.
Also, syncing Emacs with a file based cache wouldn't be that simple, probably requiring its own cache for it 😛
What I have wondered though is more, if I decide to save my own cache to a file, so on Emacs restart you don't need to re-analyse the project, if I should re-use the clj-kondo's folder, or have my own folder, or store it within Emacs's own folder, etc.