版本如何工作? [英] How does versions work

查看:89
本文介绍了版本如何工作?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,有人可以向我解释您的项目版本如何工作:)



[assembly:AssemblyVersion(1.0.0.0)]

[assembly:AssemblyFileVersion(1.0.0.0)]



每个零是什么意思,因为我已经习惯了v1.0

解决方案

请参阅我对该问题的评论。它意味着,按顺序或写作:主要,次要,构建,修订。列表中的第一个是最重要的组件,最后一个是最不重要的组件;这种按重要性排序通过实现此类的比较运算符,以此类实例的自然顺序表示。请参阅:

http:/ /msdn.microsoft.com/en-us/library/system.version%28v=vs.110%29.aspx [ ^ ]。



另请参阅: http://en.wikipedia.org/wiki/Order_theory [ ^ ]。



这些词( major,minor......)没有任何特殊含义。请注意,它们反映了Windows版本控制方法,这种方法通常也用于其他操作系统;它不是特定于.NET。例如,任何文件系统对象也会获得这样的四个版本组件。这些组件可用于实现任何合理的版本控制策略。 它是如何工作这个问题不够明确,不清楚你的问题是什么。



如果你理解了如何使用版本对象,你可以理解它的操作。 NET 属性工作:

http://en.wikipedia .org / wiki / Metadata_%28CLI%29 [ ^ ],

http ://msdn.microsoft.com/en-us/library/aa288454%28v=vs.71%29.aspx [ ^ ](过时的文章,但足以理解主题)。



参见:

http://msdn.microsoft.com/en-us/library/system .reflection.assemblyversionattribute%28v = vs.110%29.aspx [ ^ ],

http://msdn.microsoft.com/en-us/library/system.reflection.assemblyfileversionattribute%28v=vs.110%29 .aspx [ ^ ],

http://msdn.microsoft.com/en-us/library/system.attribute%28v=vs.110%29.aspx [ ^ ]。



如有任何疑问吗?



-SA

Hi there can someone explain to me how versioning your project works :)

[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

What does each zero mean, because i'm so used to v1.0

解决方案

Please see my comment to the question. It means, in the order or writing: major, minor, build, revision. First in a list is most significant component, last one is the least significant; this ordering by significance is expressed in the natural ordering of instances of this class through the implementation of the comparison operators for this class. Please see:
http://msdn.microsoft.com/en-us/library/system.version%28v=vs.110%29.aspx[^].

See also: http://en.wikipedia.org/wiki/Order_theory[^].

Those words ("major", "minor"…) don't carry any special meaning. Note that they reflect Windows versioning approach which is most usually also used in other OS; it is not specific to .NET. For example, any file system object also gets such four version components. The components can be used to implement any reasonable versioning policy. The question "how does it work" is not definitive enough, not clear what is your concern.

Probably you can understand the operation using version objects if you understand how .NET attributes work:
http://en.wikipedia.org/wiki/Metadata_%28CLI%29[^],
http://msdn.microsoft.com/en-us/library/aa288454%28v=vs.71%29.aspx[^] (obsolete article, but good enough for understanding of the subject).

See also:
http://msdn.microsoft.com/en-us/library/system.reflection.assemblyversionattribute%28v=vs.110%29.aspx[^],
http://msdn.microsoft.com/en-us/library/system.reflection.assemblyfileversionattribute%28v=vs.110%29.aspx[^],
http://msdn.microsoft.com/en-us/library/system.attribute%28v=vs.110%29.aspx[^].

Any questions about that?

—SA


这篇关于版本如何工作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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