Is there a way to ensure an MSI installer updates

2019-06-19 18:38发布

Is there some easy, hassle-free way to get the MSI installation to always replace the .exe file (i.e. Primary Output) whenever the .exe file is more recent?

This is just basic and common sense. Wherever I search there are always complicated discussions about major and minor versions and patches. There must be some simple way to ensure the file gets replaced during an install. Otherwise, what is the MSI file actually doing during the whole installation procedure. It's like a fake install where nothing actually gets replaced/updated/upgraded.

What am I missing?

3条回答
够拽才男人
2楼-- · 2019-06-19 19:06

Everything works in a "common sense" way as long as you increment the version number of the .exe. MSI trusts version info over more malleable aspects like a file's timestamp.

查看更多
Juvenile、少年°
3楼-- · 2019-06-19 19:12

Set your assembly version of your project to 1.0.* then it will automatically produce a new .exe version. You also need to make sure you increase the setup version, sadly there isn't a way to get this to auto-increment.

查看更多
地球回转人心会变
4楼-- · 2019-06-19 19:19

In File table you can set the Version column to "65535.65535.65535.65535". This way the file will always be overwritten, no matter what version it actually has.

This is not supported by Visual Studio, but you can edit the MSI with Orca.

查看更多
登录 后发表回答