Changeset 6 for trunk/Units
- Timestamp:
- May 6, 2015, 11:19:49 AM (10 years ago)
- Location:
- trunk/Units
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Units/USubversion.pas
r5 r6 14 14 TSubversion = class(TWorkingCopy) 15 15 protected 16 procedure Execute( Command: string); override;16 procedure Execute(Parameters: array of string); 17 17 public 18 18 procedure Checkout; override; … … 28 28 { TSubversion } 29 29 30 procedure TSubversion.Execute(Command: string); 30 procedure TSubversion.Execute(Parameters: array of string); 31 var 32 Params: TStringList; 31 33 begin 32 inherited Execute('svn ' + Command); 34 Params := TStringList.Create; 35 try 36 Params.AddStrings(Parameters); 37 ExecuteProcess('svn', Params); 38 finally 39 Params.Free; 40 end; 33 41 end; 34 42 35 43 procedure TSubversion.Checkout; 36 44 begin 37 Execute( 'checkout');45 Execute(['checkout']); 38 46 end; 39 47 40 48 procedure TSubversion.Update; 41 49 begin 42 Execute( 'update');50 Execute(['update']); 43 51 end; 44 52 45 53 procedure TSubversion.CleanUp; 46 54 begin 47 Execute( 'cleanup');55 Execute(['cleanup']); 48 56 end; 49 57 50 58 procedure TSubversion.Commit; 51 59 begin 52 Execute( 'commit');60 Execute(['commit']); 53 61 end; 54 62 55 63 procedure TSubversion.Move; 56 64 begin 57 Execute( 'move');65 Execute(['move']); 58 66 end; 59 67 60 68 procedure TSubversion.Merge; 61 69 begin 62 Execute( 'merge');70 Execute(['merge']); 63 71 end; 64 72 -
trunk/Units/UVCS.pas
r5 r6 17 17 procedure SetPath(AValue: string); 18 18 protected 19 procedure Execute (Command: string); virtual;19 procedure ExecuteProcess(Command: string; Parameters: TStrings); virtual; 20 20 public 21 21 procedure Checkout; virtual; … … 48 48 end; 49 49 50 procedure TWorkingCopy.Execute (Command: string);50 procedure TWorkingCopy.ExecuteProcess(Command: string; Parameters: TStrings); 51 51 begin 52 FormConsole.Executable := 'svn';53 FormConsole.Parameters.A dd(Command);52 FormConsole.Executable := Command; 53 FormConsole.Parameters.Assign(Parameters); 54 54 FormConsole.WorkingDir := Path; 55 FormConsole. Perform;55 FormConsole.ShowModal; 56 56 end; 57 57
Note:
See TracChangeset
for help on using the changeset viewer.