发布版VS大会(ETC)版本 [英] Publish Version vs Assembly (etc) Versions

查看:159
本文介绍了发布版VS大会(ETC)版本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我读过线程在这里对大会文件和大会信息化版本。

I've read threads here about the Assembly, File and Assembly Informational versions.

我想知道在哪里发布的版本合适。... ...的结果

I'd like to know where the Publish version fits in. The result of...

string thisAppsVersion = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString();

...似乎是的AssemblyVersion。到现在为止,我一直在使用发布版本部署类:

...appears to be the AssemblyVersion. Up until now I've been using the publish version with the deployment class:

ApplicationDeployment deployment = ApplicationDeployment.CurrentDeployment;
Version thisAppsVersion = deployment.CurrentVersion;

...但这不是可用的,除非安装该应用。我喜欢它如何选择自动递增修订。

...but this isn't available unless the app is installed. I like how it has the option to automatically increment the Revision.

有没有办法让没有被网络部署的发布版本?它应该是对应用程序的版本的大众脸?

Is there a way to get the publish version without being network deployed? Should it be the 'public face' of the app's version?

例:UI版本(从发布版扭曲)

在此先感谢!

格雷格

推荐答案

我觉得不同的版本满足不同的目的。

I think the different versions serve different purpose.

1)的AssemblyVersion是CLR加载和绑定组件。这对开发人员有用的,但不是最终用户。

1) AssemblyVersion is for CLR to load and bind assemblies. This is useful for developers but not end-users.

2)文件版本或AssemblyFileVersion是什么窗口显示可执行文件的文件版本。这是完全一样的Win32应用程序的版本。这个版本所使用的系统和安装,以确定哪些版本更新

2) FileVersion or AssemblyFileVersion is what Windows displayed as the executable's file version. It is just the same Win32 application's version. And this version is used by the system and installers to determine which version is newer.

3)PublishVersion用于版本部署包。它是确定有不同的发布版本发布两次相同的二进制文件。

3) PublishVersion is used to version the deployment package. It is OK to have the same binaries published twice with different publish versions.

4)你给你的最终用户的版本是另一个版本。说它是产品版本或别的东西。它可从任何上述的,用于例如不同商业用途。请参阅<一href="http://msdn.microsoft.com/en-us/library/system.reflection.assemblyinformationalversionattribute.aspx">AssemblyInformationalVersionAttribute如果你想使用一些.NET内置的支持。

4) The version you show to your end-users is yet another version. Call it product version or something else. It may different from any of the above, for e.g. business purpose. See AssemblyInformationalVersionAttribute if you want to use some .NET built-in support.

对于简单的情况下,你可以使用文件版本,产品版本。但发布的版本是不是一个好主意,我。

For simple cases, you may use the FileVersion as the product version. But publish version is not a good idea to me.

这篇关于发布版VS大会(ETC)版本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆