scm: git: split adapter entries() for browsing tree performance (#7047).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5639 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
1 parent
905a809774
commit
97b4ee2fef
1 file changed
+5
@@ -107,6 +107,10 @@ module Redmine
|
|||||||
end
|
end
|
||||||
|
|
||||||
def entries(path=nil, identifier=nil, options={})
|
def entries(path=nil, identifier=nil, options={})
|
||||||
|
entries_git(path, identifier, options)
|
||||||
|
end
|
||||||
|
|
||||||
|
def entries_git(path=nil, identifier=nil, options={})
|
||||||
path ||= ''
|
path ||= ''
|
||||||
p = scm_iconv(@path_encoding, 'UTF-8', path)
|
p = scm_iconv(@path_encoding, 'UTF-8', path)
|
||||||
entries = Entries.new
|
entries = Entries.new
|
||||||
@@ -140,6 +144,7 @@ module Redmine
|
|||||||
rescue ScmCommandAborted
|
rescue ScmCommandAborted
|
||||||
nil
|
nil
|
||||||
end
|
end
|
||||||
|
private :entries_git
|
||||||
|
|
||||||
def lastrev(path, rev)
|
def lastrev(path, rev)
|
||||||
return nil if path.nil?
|
return nil if path.nil?
|
||||||
|
|||||||
Reference in new issue
Block a user