小编Pra*_*een的帖子

从svn更新之前,检查本地目录是一个工作副本

我正在使用c#编程提取svn存储库.我已将sharpsvn dll添加到我的项目中并编写了以下代码

string localFolder= @"C:\Users\Desktop\LocalFolder\Dev\Websites\Service";
SvnClient client = new SvnClient();

SvnUriTarget target = new SvnUriTarget(@"http://svn.user.com/svn/websites/Branches/InternalServices");

SvnInfoEventArgs info;

client.GetInfo(target, out info);

//Specify the repository root as Uri
//Console.WriteLine("Repository version: {0}", info.Revision);
Console.WriteLine("Started checking out. Please wait few minutes");

client.CheckOut(target, localFolder);                   
//client.Update(localFolder);
Run Code Online (Sandbox Code Playgroud)

我已经使用'client.checkout'方法检查了,我可以使用'client.update'方法进行更新.

假设我的机器中有'服务'文件夹.我最初使用'client.checkout'检出文件/文件夹到这个文件夹.

下次运行程序时,它应该自动更新而不用结帐.我怎么知道服务文件夹是否已经完成了一次结账,现在它应该更新?

c# sharpsvn

0
推荐指数
1
解决办法
3500
查看次数

标签 统计

c# ×1

sharpsvn ×1