use of org.apache.maven.scm.provider.tfs.TfsScmProviderRepository in project maven-scm by apache.
the class TfsTagCommand method createCommand.
public TfsCommand createCommand(ScmProviderRepository r, ScmFileSet f, String tag, ScmTagParameters scmTagParameters) {
TfsScmProviderRepository tfsRepo = (TfsScmProviderRepository) r;
String url = tfsRepo.getServerPath();
TfsCommand command = new TfsCommand("label", r, f, getLogger());
command.addArgument(tag);
command.addArgument(url);
command.addArgument("-recursive");
command.addArgument("-child:replace");
String message = scmTagParameters.getMessage();
if (message != null && !message.equals("")) {
command.addArgument("-comment:" + message);
}
return command;
}
use of org.apache.maven.scm.provider.tfs.TfsScmProviderRepository in project maven-scm by apache.
the class TfsCheckInCommand method createCommand.
public TfsCommand createCommand(ScmProviderRepository r, ScmFileSet f, String m) {
TfsCommand command = new TfsCommand("checkin", r, f, getLogger());
command.addArgument("-noprompt");
if (StringUtils.isNotBlank(m)) {
command.addArgument("-comment:" + m);
}
command.addArgument(f);
TfsScmProviderRepository tfsScmProviderRepo = (TfsScmProviderRepository) r;
if (tfsScmProviderRepo.isUseCheckinPolicies()) {
// handle TFS-policies (by adding "/override:";Auto-Build: Version Update";)
command.addArgument("/override:checkin_policy");
}
return command;
}
use of org.apache.maven.scm.provider.tfs.TfsScmProviderRepository in project maven-scm by apache.
the class TfsUnEditCommandTest method testCommandline.
public void testCommandline() throws Exception {
TfsScmProviderRepository repo = getScmProviderRepository();
Commandline cmd = new TfsUnEditCommand().createCommand(repo, getScmFileSet()).getCommandline();
String expected = "tf undo -login:user,password " + getFileList();
assertCommandLine(expected, getWorkingDirectory(), cmd);
}
use of org.apache.maven.scm.provider.tfs.TfsScmProviderRepository in project maven-scm by apache.
the class TfsEditCommandTest method testCommandline.
public void testCommandline() throws Exception {
TfsScmProviderRepository repo = getScmProviderRepository();
Commandline cmd = new TfsEditCommand().createCommand(repo, getScmFileSet()).getCommandline();
String expected = "tf checkout -login:user,password " + getFileList();
assertCommandLine(expected, getWorkingDirectory(), cmd);
}
use of org.apache.maven.scm.provider.tfs.TfsScmProviderRepository in project maven-scm by apache.
the class TfsBranchCommandTest method testCommandline.
public void testCommandline() throws Exception {
TfsScmProviderRepository repo = getScmProviderRepository();
Commandline cmd = new TfsBranchCommand().createCommand(repo, getScmFileSet(), "branch").getCommandline();
String serverPath = "serverpath";
String expected = "tf branch -login:user,password " + serverPath + " -checkin branch";
assertCommandLine(expected, getWorkingDirectory(), cmd);
}
Aggregations