CLI (InspectCode) to share temp directory with R# VS plugin


Our team is currently utilizing local R# plugins as well as TeamCity on our build server. I'm looking to integrate the InspectCode CLI tool into our local build process.
So far I'm able to point it to our shared master DotSettings file and it works great. However, it does take a while to run (understandably.) All our developers (should) have solution-wide analysis already turned on in the Visual Studio plugin, so is there a way to make the InspectCode CLI tool use the same cache files that are generated by the R# plugin?

Thanks in advance!

Comment actions Permalink

You can use the /caches-home parameter to point InspectCode.exe to a particular location.

Comment actions Permalink

Thank you for the reply.

Let me clarify. Our R# plugins are set to use the user local settings folder. The actual cache location is:
C:/Users/(userName)/AppData/Local/JetBrains/ReSharper/v(R# version)/SolutionCaches

Inside that folder there are sub-folders generated by R# named like the following:

However, the CodeInspect tool generates sub-folders like the following:

Therefore, my best effort is to use the flag:
/caches-home="C:/Users/(userName)/AppData/Local/JetBrains/ReSharper/v(R# version)/SolutionCaches"

But this offers no benefit as the CLI tool generates its own sub-directories anyway (even though they appear to contain the same stuff as the R# solution cache auto-generated folders). Is it not possible for them to use the same caches?


Comment actions Permalink

Ah, yes. I see what you mean now. Unfortunately, there isn't a way to get them to share a cache - the product name is in the cache folder, and that's different between ReSharper and InspectCode. However, InspectCode should re-use any existing cache, only analysing files that have changed, rather than building everything from scratch, so it should have some kind of a speed up.


Please sign in to leave a comment.