-
Notifications
You must be signed in to change notification settings - Fork 399
Expand file tree
/
Copy pathClone.cs
More file actions
24 lines (21 loc) · 735 Bytes
/
Clone.cs
File metadata and controls
24 lines (21 loc) · 735 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
using System.Text;
namespace SourceGit.Commands
{
public class Clone : Command
{
public Clone(string ctx, string path, string url, string localName, string sshKey, string extraArgs)
{
Context = ctx;
WorkingDirectory = path;
SSHKey = sshKey;
var builder = new StringBuilder(1024);
builder.Append("clone --progress --verbose ");
if (!string.IsNullOrEmpty(extraArgs))
builder.Append(extraArgs).Append(' ');
builder.Append(url.Quoted()).Append(' ');
if (!string.IsNullOrEmpty(localName))
builder.Append(localName.Quoted());
Args = builder.ToString();
}
}
}