如何在*.CS文件中加入版本跟踪信息?
2005-01-15 18:43
537 查看
说起来很惭愧,一直以来竟然不知道VSS的这个功能。在 博客园 看到一个随笔提到了这个功能,但是描述的不尽详细,我也是询问了一个同事才知道如何正确的配置VSS来实现这个功能,这里面简要的分享给大家,希望能有所帮助。
以前使用CVS知道里面有几个宏参数可以使用,比如:$Header$等等,但并不知道VSS中也可以使用,Google了一下,发现在VSS中可以使用如下:
首先用Admin登录VSS的系统管理界面,选择“Options”:
550)this.width=550;" border=0>
做如下设置:
550)this.width=550;" border=0>
接着每个开发者的VSS都必须是VSS6.0d,如果不是,就需要更新!VSS6.0c不可以。
550)this.width=550;" border=0>
550)this.width=550;" border=0>
最后需要在每一个.CS文件的最开头加入如下代码:
/*
$Header$
$Author$
$Date$
$Revision$
$History$
*/
这样,每次更改之后就会自动出现如下历史信息(请不要手动去更改):
/*
$Header: /Development/DailyReport/frmMain.cs 13 05-01-14 10:27 Uestc95 $
$Author: Uestc95 $
$Date: 05-01-14 10:27 $
$Revision: 13 $
$History: frmMain.cs $
*
* ***************** Version 13 *****************
* User: Uestc95 Date: 05-01-14 Time: 10:27
* Updated in $/Development/DailyReport
*
* ***************** Version 12 *****************
* User: Uestc95 Date: 05-01-14 Time: 10:25
* Updated in $/Development/DailyReport
*
* ***************** Version 11 *****************
* User: Uestc95 Date: 05-01-14 Time: 10:06
* Updated in $/Development/DailyReport
*/
以前使用CVS知道里面有几个宏参数可以使用,比如:$Header$等等,但并不知道VSS中也可以使用,Google了一下,发现在VSS中可以使用如下:
Type this keyword | To add the following |
$Archive: $ | VSS archive file location |
$Author: $ | User who last changed the file |
$Date: $ | Date and time of last check in |
$Header: $ | Logfile, Revision, Date, Author |
$History: $ | File history, VSS format |
$JustDate: $ | Date, without the time addendum. |
$Log: $ | File history, RCS format |
$Logfile: $ | Same as Archive |
$Modtime: $ | Date and time of last modification |
$Revision: $ | VSS version number |
$Workfile: $ | File name |
$NoKeywords: $ | No keyword expansion for all keywords that follow |
550)this.width=550;" border=0>
做如下设置:
550)this.width=550;" border=0>
接着每个开发者的VSS都必须是VSS6.0d,如果不是,就需要更新!VSS6.0c不可以。
550)this.width=550;" border=0>
550)this.width=550;" border=0>
最后需要在每一个.CS文件的最开头加入如下代码:
/*
$Header$
$Author$
$Date$
$Revision$
$History$
*/
这样,每次更改之后就会自动出现如下历史信息(请不要手动去更改):
/*
$Header: /Development/DailyReport/frmMain.cs 13 05-01-14 10:27 Uestc95 $
$Author: Uestc95 $
$Date: 05-01-14 10:27 $
$Revision: 13 $
$History: frmMain.cs $
*
* ***************** Version 13 *****************
* User: Uestc95 Date: 05-01-14 Time: 10:27
* Updated in $/Development/DailyReport
*
* ***************** Version 12 *****************
* User: Uestc95 Date: 05-01-14 Time: 10:25
* Updated in $/Development/DailyReport
*
* ***************** Version 11 *****************
* User: Uestc95 Date: 05-01-14 Time: 10:06
* Updated in $/Development/DailyReport
*/
相关文章推荐
- [.NET Tips 1001]如何在*.CS文件中加入版本跟踪信息?
- 在*.cs文件中加入版本跟踪信息
- 关于昨天说的“在*.CS文件中加入版本跟踪信息”问题
- 【Android】app打包成apk文件以后,如何查看VersionCode、VersionName等版本信息
- Eclipse + CVS 之 如何将文件加入版本控制和脱离版本控制
- 在CAD编辑器中如何查询文件的版本信息
- 如何查看.mdf文件数据库版本信息
- 在DLL文件中加入版本信息、描述信息的方法
- 采用System.Reflection.Emit动态建立程序集如何设置文件的版本信息,描述等信息
- Eclipse中与CVS相连的工程中的文件,不显示版本信息时,如何处理(重启Eclipse)!
- Eclipse + CVS 之 如何将文件加入版本控制和脱离版本控制
- IAR开发STM8,如何加入每次编译的日期时间信息来做为版本信息
- 如何给VC之Win32生成的.exe文件添加版本信息
- 在Windows Mobile和Wince(Windows Embedded CE)下进行Native C++开发,如何取出资源文件中的版本信息
- 如何查看JAVA类文件的编译JDK版本信息
- 如何查看linux动态链接库文件的版本等其他信息
- 在cs文件加入版本信息
- Eclipse + CVS 之如何将文件加入版本控制和脱离版本
- Qt 如何把版本信息加入应用程序
- 跳到文件指定位置加入版本信息