如何找到特定 Subversion 用户所做的修订? [英] How do I find the revisions made by a specific Subversion user?
问题描述
使用命令行,我想查看特定用户所做的所有变更集.这可能吗?我查看了 svn log
的文档,但不知道如何执行此操作.
Using the command line, I'd like to see all changesets made by a particular user. Is this possible? I've looked at the documentation for svn log
but can't see how to do this.
推荐答案
我不知道使用纯 Subversion 有什么方法可以做到这一点.但是你可以使用sed
一个>:
I don't know of any way to do this using pure Subversion. But you can do it with sed
:
svn log | sed -n '/username/,/-----$/ p'
这会找到用户名的每个实例,然后打印所有内容,直到标记日志中记录结束的虚线为止.
This finds each instance of the username, and then prints everything up to the dashed line which marks the end of a record in the log.
搜索模式非常灵活 - 您可以轻松修改它以搜索其他内容.例如,
The search pattern is very flexible - you can easily modify it to search for other things. For example,
svn log | sed -n '/Dec 2009/,/-----$/ p'
将返回 12 月的所有提交(任何作者).
Would return all commits made in December (by any author).
如果您不想要实际的提交消息,而只想要摘要元数据,那么您可以使用 grep
,类似于 William Leara 的Windows 答案一个>:
If you don't want the actual commit message, but just the summary metadata, then you can just use grep
, in an analogous way to William Leara's Windows answer:
svn log | grep username
这篇关于如何找到特定 Subversion 用户所做的修订?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!