public void TestAddTag() { CvsRoot root = new CvsRoot(this.settings.Config.Cvsroot); WorkingDirectory workingDirectory = new WorkingDirectory(root, this.settings.Config.LocalPath, this.settings.Config.Module); CVSServerConnection connection = new CVSServerConnection(); this.Checkout(workingDirectory, connection); RTagCommand command = new RTagCommand(workingDirectory); command.TagName = TEST_TAG_1; connection.Connect(workingDirectory, this.settings.ValidPassword); command.Execute(connection); }
/// <summary> /// Create the command object that will be used to act on the repository. /// </summary> /// <returns>The command object that will be used to act on the /// repository.</returns> /// <exception cref="Exception">TODO: Make a more specific exception</exception> /// <exception cref="NotImplementedException">If the command argument /// is not implemented currently. TODO: Implement the argument.</exception> public override ICommand CreateCommand() { ICSharpCode.SharpCvsLib.Commands.RTagCommand rtagCommand; try { this.ParseOptions(this.unparsedOptions); if (localDirectory == null) { localDirectory = Environment.CurrentDirectory; } CurrentWorkingDirectory = new WorkingDirectory(this.cvsRoot, localDirectory, repository); // Create new RTagCommand object rtagCommand = new ICSharpCode.SharpCvsLib.Commands.RTagCommand( this.CurrentWorkingDirectory); } catch (Exception e) { LOGGER.Error(e); throw e; } return(rtagCommand); }
/// <summary> /// Create the command object that will be used to act on the repository. /// </summary> /// <returns>The command object that will be used to act on the /// repository.</returns> /// <exception cref="Exception">TODO: Make a more specific exception</exception> /// <exception cref="NotImplementedException">If the command argument /// is not implemented currently. TODO: Implement the argument.</exception> public override ICommand CreateCommand () { ICSharpCode.SharpCvsLib.Commands.RTagCommand rtagCommand; try { this.ParseOptions(this.unparsedOptions); if (localDirectory == null) { localDirectory = Environment.CurrentDirectory; } CurrentWorkingDirectory = new WorkingDirectory( this.cvsRoot, localDirectory, repository); // Create new RTagCommand object rtagCommand = new ICSharpCode.SharpCvsLib.Commands.RTagCommand( this.CurrentWorkingDirectory ); } catch (Exception e) { LOGGER.Error (e); throw e; } return rtagCommand; }