Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is ResolveAssemblyReference.cache?

What is the file ResolveAssemblyReference.cache used for and does it need to be checked in?

like image 712
Ken Avatar asked Jan 06 '11 19:01

Ken


2 Answers

It is a file produced by the ResolveAssemblyReference build target. MSDN has this to say about it:

Visual Studio attempts to execute targets with certain names when it loads a project. These targets include Compile, ResolveAssemblyReferences, ResolveCOMReferences, GetFrameworkPaths, and CopyRunEnvironmentFiles. Visual Studio runs these targets so that the compiler can be initialized to provide IntelliSense, the debugger can be initialized, and references displayed in Solution Explorer can be resolved. If these targets are not present, the project will load and build correctly but the design-time experience in Visual Studio will not be fully functional.

If I interpret this correctly, I'd say that the file is used to help the IDE provide proper IntelliSense and assembly reference status in the References node. It is a fairly expensive operation since there are potentially a lot of assemblies that can be referenced. So instead of doing this repeatedly, the .cache file can help make this quick. Deleting it isn't an issue, it will be recreated when the project is reloaded.

like image 164
Hans Passant Avatar answered Oct 21 '22 05:10

Hans Passant


It is not needed to be checked in, so to exclude it from git, add the obj folder, for "obj\debug", to be excluded during git processes which will exclude it properly.

like image 44
Amit Ghave Avatar answered Oct 21 '22 06:10

Amit Ghave