is it possible to tell if an assembly has changed?
I have a standard project that generates an assembly called MyAssembly.dll.
In a separate project i read the assembly and generate a hash.
When i generate a hash for the assembly it is different each time i recompile. I have set the assembly version to be static, are there any other attributes that i need to change?
class Program
{
static void Main(string[] args)
{
var array = File.ReadAllBytes(@"MyAssembly.dll");
SHA256Managed algo = new SHA256Managed();
var hash = algo.ComputeHash(array);
Console.WriteLine(Convert.ToBase64String(hash));
}
}
Thanks
Rohan