@@ -103,32 +103,36 module Redmine | |||
|
103 | 103 | cmd_args << "-D" << time_to_cvstime(identifier) if identifier |
|
104 | 104 | cmd_args << path_with_project |
|
105 | 105 | scm_cmd(*cmd_args) do |io| |
|
106 |
io.each_line() |
|
|
107 | fields=line.chop.split('/',-1) | |
|
106 | io.each_line() do |line| | |
|
107 | fields = line.chop.split('/',-1) | |
|
108 | 108 | logger.debug(">>InspectLine #{fields.inspect}") |
|
109 | ||
|
110 | 109 | if fields[0]!="D" |
|
111 |
entries << Entry.new( |
|
|
110 | entries << Entry.new( | |
|
111 | { | |
|
112 | :name => fields[-5], | |
|
112 | 113 | #:path => fields[-4].include?(path)?fields[-4]:(path + "/"+ fields[-4]), |
|
113 | 114 | :path => "#{path}/#{fields[-5]}", |
|
114 | 115 | :kind => 'file', |
|
115 | 116 | :size => nil, |
|
116 |
:lastrev => Revision.new( |
|
|
117 |
|
|
|
118 |
|
|
|
119 |
|
|
|
120 | :author => '' | |
|
117 | :lastrev => Revision.new( | |
|
118 | { | |
|
119 | :revision => fields[-4], | |
|
120 | :name => fields[-4], | |
|
121 | :time => Time.parse(fields[-3]), | |
|
122 | :author => '' | |
|
123 | }) | |
|
121 | 124 | }) |
|
122 | }) | |
|
123 | 125 | else |
|
124 |
entries << Entry.new( |
|
|
126 | entries << Entry.new( | |
|
127 | { | |
|
128 | :name => fields[1], | |
|
125 | 129 | :path => "#{path}/#{fields[1]}", |
|
126 | 130 | :kind => 'dir', |
|
127 | 131 | :size => nil, |
|
128 | 132 | :lastrev => nil |
|
129 | }) | |
|
133 | }) | |
|
130 | 134 | end |
|
131 |
|
|
|
135 | end | |
|
132 | 136 | end |
|
133 | 137 | entries.sort_by_name |
|
134 | 138 | rescue ScmCommandAborted |
General Comments 0
You need to be logged in to leave comments.
Login now