summaryrefslogtreecommitdiffstats
path: root/app/models/repository
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-05-12 07:06:57 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-05-12 07:06:57 +0000
commitcddc5f70a32b3f7674c41ffa970f58b3075f0a6e (patch)
tree1876f04e95abe83268ff2ce4e42d8b1605c3dea9 /app/models/repository
parent092cfc02293d525dcc6e2f2bf9eefe9e6cceb5f0 (diff)
downloadredmine-cddc5f70a32b3f7674c41ffa970f58b3075f0a6e.tar.gz
redmine-cddc5f70a32b3f7674c41ffa970f58b3075f0a6e.zip
scm: git: code clean up model.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5750 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/repository')
-rw-r--r--app/models/repository/git.rb17
1 files changed, 9 insertions, 8 deletions
diff --git a/app/models/repository/git.rb b/app/models/repository/git.rb
index 828a7ffb6..f02cf1505 100644
--- a/app/models/repository/git.rb
+++ b/app/models/repository/git.rb
@@ -1,16 +1,17 @@
-# redMine - project management software
-# Copyright (C) 2006-2007 Jean-Philippe Lang
+# Redmine - project management software
+# Copyright (C) 2006-2011 Jean-Philippe Lang
# Copyright (C) 2007 Patrick Aljord patcito@Ĺ‹mail.com
+#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
-#
+#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-#
+#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -84,7 +85,7 @@ class Repository::Git < Repository
# Mercurial fixed issues.
# * Redmine Takes Too Long On Large Mercurial Repository
# http://www.redmine.org/issues/3449
- # * Sorting for changesets might go wrong on Mercurial repos
+ # * Sorting for changesets might go wrong on Mercurial repos
# http://www.redmine.org/issues/3567
# Database revision column is text, so Redmine can not sort by revision.
# Mercurial has revision number, and revision number guarantees revision order.
@@ -138,7 +139,7 @@ class Repository::Git < Repository
:repository => self,
:revision => rev.identifier,
:scmid => rev.scmid,
- :committer => rev.author,
+ :committer => rev.author,
:committed_on => rev.time,
:comments => rev.message
)
@@ -158,9 +159,9 @@ class Repository::Git < Repository
return [] if revisions.nil? || revisions.empty?
changesets.find(
- :all,
+ :all,
:conditions => [
- "scmid IN (?)",
+ "scmid IN (?)",
revisions.map!{|c| c.scmid}
],
:order => 'committed_on DESC'