Changeset 11 for trunk/Backends/Subversion
- Timestamp:
- May 19, 2015, 11:33:02 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Backends/Subversion/USubversion.pas
r10 r11 31 31 procedure Merge; override; 32 32 procedure Add(FileName: string); override; 33 procedure GetLog(FileName: string; Log: TLogList); override; 33 34 end; 34 35 … … 91 92 end; 92 93 94 procedure TSubversion.GetLog(FileName: string; Log: TLogList); 95 var 96 NewItem: TLogItem; 97 I: Integer; 98 Line: string; 99 ChangedFiles: Boolean; 100 Action: string; 101 begin 102 NewItem := nil; 103 Log.Clear; 104 Execute(['log', FileName, '-v']); 105 for I := 0 to ExecutionOutput.Count - 1 do begin 106 Line := Trim(ExecutionOutput[I]); 107 if Line = '------------------------------------------------------------------------' then begin 108 if Assigned(NewItem) then Log.Add(NewItem); 109 NewItem := TLogItem.Create; 110 end else 111 if Pos('|', Line) > 0 then begin 112 NewItem.Revision := Trim(GetNext(Line, '|')); 113 NewItem.Author := Trim(GetNext(Line, '|')); 114 GetNext(Line, '|'); 115 //NewItem.Time := StrToDateTime(Trim(GetNext(Line, '|'))); 116 end else 117 if Line = 'Changed paths:' then begin 118 ChangedFiles := True; 119 end else 120 if ChangedFiles then begin 121 if (Line <> '') and (Copy(ExecutionOutput[I], 1, 3) = ' ') then begin 122 Action := GetNext(Line, ' '); 123 NewItem.Actions := NewItem.Actions + Action; 124 NewItem.ChangedFiles.Add(Line); 125 end else 126 if Line = '' then begin 127 ChangedFiles := False; 128 end; 129 end else 130 NewItem.Messages.Add(Line); 131 end; 132 if Assigned(NewItem) then Log.Add(NewItem); 133 end; 134 93 135 end. 94 136
Note:
See TracChangeset
for help on using the changeset viewer.