SharpSVN读取所有文件名 [英] SharpSVN read ALL filenames
本文介绍了SharpSVN读取所有文件名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
还是有点上SharpSVN一个的n00b的,我希望得到一些简单的代码在一个特定的文件夹中打开了一个SVN仓库,并读取(至少)的所有文件的完整路径。
still a bit of a n00b on SharpSVN, I'm looking to get some simple code to open up an SVN repository, and read (at least) the full path of all files in a specific folder.
比方说,这个文件夹是\trunk\source
Lets say that this folder is \trunk\source
我不希望签或承诺,只是读入名单
I'm not looking to checkout or commit, just read into a list
我也期待阅读的所有文件,而不仅仅是改变的。
I'm also looking to read ALL files, not just the changed ones.
推荐答案
确定它看起来像我找到了一个方法。
ok it looks like I found a method..
bool gotList;
List<string> files = new List<string>();
using (SvnClient client = new SvnClient())
{
Collection<SvnListEventArgs> list;
gotList = client.GetList(projectPath, out list);
if (gotList)
{
foreach (SvnListEventArgs item in list)
{
files.Add(item.Path);
}
}
}
这篇关于SharpSVN读取所有文件名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文