Search code examples
c#.netbundleassemblyinfo

Best practice bundle product versioning (assembly info)


I am just about to introduce bundle version to one product (.net c#) into AssemblyInfo.cs file and I have a question if is possible to create new assembly info parameter (BundleVersion), which could bring the defined version number into .dll details, similar as AssemblyFileVersion (file version visible metadata).

The problem is that when I try to use AssemblyMetadata

[assembly: AssemblyMetadata("BundleVersion", "1.0")]

this attribute is not visible in file -> Properties -> Details BundleVersion is not visible

Does anyone know how to "make" it visible?

The point of everything is to make the same bundle version across the products, which can talk to each other (something similar as dependency version).


Solution

  • I don't think it is possible.

    First, those properties are embedded in the .NET assembly header, not the Windows file properties. So it isn't directly accessible in Windows. Another thing is, you need to change that File Properties window by hand.

    You can get and set the properties (see Read/Write 'Extended' file properties (C#)), but adapting that window needs some hard code win32 programming, which is too much I guess.

    The only suggestion I have left is: put the value in one of the properties already available and used in Windows. That's your best and easiest option.