开发者

Getting date of a revision using svn info

开发者 https://www.devze.com 2023-04-13 04:21 出处:网络
My objective is to extract revisions from the repository that are at least 30 days apart from each other. Lets say I want to examine revisions starting from 30 to 100. For each of the revisions, I hav

My objective is to extract revisions from the repository that are at least 30 days apart from each other. Lets say I want to examine revisions starting from 30 to 100. For each of the revisions, I have used SVN info command and use the last changed date as the date of that开发者_高级运维 revision. The next steps are straightforward. Check the difference in days between two consecutive revisions.

My question is whether the approach is ok (or in another way, is it correct to get the date of a revision in this approach). Any suggestion would be helpful. Thanks.

Example of SVN info output.

$ svn info -r 200 https://itextsharp.svn.sourceforge.net/svnroot/itextsharp/trunk
Path: trunk
URL: https://itextsharp.svn.sourceforge.net/svnroot/itextsharp/trunk
Repository Root: https://itextsharp.svn.sourceforge.net/svnroot/itextsharp
Repository UUID: da003780-e18d-4f51-86a4-c2ecb517afe5
Revision: 200
Node Kind: directory
Last Changed Author: psoares33
Last Changed Rev: 200
Last Changed Date: 2010-10-17 12:25:23 -0600 (Sun, 17 Oct 2010)


You are probably better off using the svn log command, with the --xml option for automated parsing. This will give you a quick list of revisions, including the dates.


svn log -r {DATESPEC}:{DATESPEC}/rev-id will work better

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号