问题
Is there a better way to modify the version information of a .NET assembly of the one I am currently using.
My current approach is the following.
I do disassemble the assembly with ildasm:
ildasm /nobar Riolo.WebUI.dll /out=Riolo.WebUI.il
This will generated also a Riolo.WebUI.res compiled resource file, that I then open and modify with the user interface of Visual Studio, then I do reassemble the assembly back with ilasm:
ilasm Riolo.WebUI.il /OUTPUT=Riolo.WebUI.dll /RESOURCE=Riolo.WebUI.res /DLL /PDB
There are various issues with this process, the main is obviously that I feel like shooting at a mosquito with a broadside of carronades, then that as I don't know how decompile .res
files to .rc
files with the command line, I cannot use a command line script, as I have to open Visual Studio to modify the .res
file, which means it is very time consuming and somewhat error prone, and, last but not least, I do feel that roundtripping assemblies I may well end up loosing information, even if unwittingly, hence I am afraid I will early or later be bitten in some yet unforeseen scenario.
来源:https://stackoverflow.com/questions/7659818/modify-the-version-information-of-a-built-net-assembly