简体   繁体   English

如何使用SVNKit获取日志/历史记录给定的特定文件列表?

[英]How to get the Log / History give a specific file list using SVNKit?

Given a file list for example A.java, B.java, C.java, D.java, I want to get the History / Log of the file that are present in the file list. 给定一个文件列表,例如A.java,B.java,C.java,D.java,我想获取文件列表中存在的文件的历史记录/日志。

For example 例如

Revision 0

Added file A.java

Added file B.java

Revision 1

Modified file B.java

Deleted file A.java

Added file C.java

Revision 2

Added file D.java

Modified file B.java

Modified file C.java

Revision 3

Deleted file  C.java

etc... 等等...

The history should ONLY show the logs (added/ delete/ modified) of the files in the file list. 历史记录仅应在文件列表中显示文件的日志(添加/删除/修改)。

How can I do this? 我怎样才能做到这一点? It'll would be nice if you will provided some code snippet. 如果您将提供一些代码片段,那就太好了。

For local files, have a look at org.tmatesoft.svn.core.wc.SVNLogClient#doLog or do the log directly against the repository using org.tmatesoft.svn.core.io.SVNRepository#log . 对于本地文件,请查看org.tmatesoft.svn.core.wc.SVNLogClient#doLog或使用org.tmatesoft.svn.core.io.SVNRepository#log直接针对存储库进行org.tmatesoft.svn.core.io.SVNRepository#log The code snippet can be found at http://wiki.svnkit.com/Printing_Out_Repository_History . 可以在http://wiki.svnkit.com/Printing_Out_Repository_History中找到该代码段。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM