如何获取特定日期或日期范围内的 SVN 修订号 [英] How to get the SVN revision number in certain Date or date range

查看:41
本文介绍了如何获取特定日期或日期范围内的 SVN 修订号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何获取某个日期某个分支的修订号.

How can I get the revision number of a branch on certain date.

我试过了:

svn checkout -r {2006-02-17}

但无法得到任何输出.

推荐答案

 svn co -r {2011-11-28} svn://location/of/my/repository/branch

对我有用.可能是您缺少 URL.但是,如果我尝试查看 repo 不存在的时间的修订版,我会得到

works for me. May be you are missing URL. however if I try to checkout a revision of a time when repo did not exist, I get

svn co -r {2006-11-28} svn://location/of/my/repository/branch
svn: Unable to find repository location for 'svn://location/of/my/repository/branch' in revision 0

<小时>

更新阅读您的评论后,您似乎只对查看日期范围内的提交文件感兴趣.这是我所做的:


Update After reading your comment you seem to be just interested in seeing committed file in a date range. Here is what I do:

svn log -r {2011-12-02}
------------------------------------------------------------------------
r10514 | nishant | 2011-12-01 22:47:44 +0000 (Thu, 01 Dec 2011) | 1 line

fixed issue#2993
------------------------------------------------------------------------

参考:SVN 文档修订说明 阅读为什么它会为前一天的提交提供结果.

更新:
修订范围不适用于日期.

Update:
Revision range is not applied on date.

svn co -r {2012-09-04}:{2012-09-14} svn://location/of/my/repository/branch
svn: Revision range is not allowed

但是,如果您只想查看两个日期范围之间更改的文件.看看日志

However, if you just wanted to see the files altered between two date range. Just see the log

  svn log -r {2012-09-04}:{2012-09-14}

这篇关于如何获取特定日期或日期范围内的 SVN 修订号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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