BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
6d93eafa
Commit
6d93eafa
authored
Dec 20, 2012
by
Koen Punt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
disabled sorting of commits before compare
parent
a09d9382
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
8 deletions
+4
-8
commit.rb
app/models/commit.rb
+4
-8
No files found.
app/models/commit.rb
View file @
6d93eafa
...
...
@@ -87,14 +87,10 @@ class Commit
last
=
project
.
commit
(
from
.
try
(
:strip
))
if
first
&&
last
commits
=
[
first
,
last
].
sort_by
(
&
:created_at
)
younger
=
commits
.
first
older
=
commits
.
last
result
[
:same
]
=
(
younger
.
id
==
older
.
id
)
result
[
:commits
]
=
project
.
repo
.
commits_between
(
older
.
id
,
younger
.
id
).
map
{
|
c
|
Commit
.
new
(
c
)}
result
[
:diffs
]
=
project
.
repo
.
diff
(
younger
.
id
,
older
.
id
)
rescue
[]
result
[
:commit
]
=
Commit
.
new
(
older
)
result
[
:same
]
=
(
first
.
id
==
last
.
id
)
result
[
:commits
]
=
project
.
repo
.
commits_between
(
last
.
id
,
first
.
id
).
map
{
|
c
|
Commit
.
new
(
c
)}
result
[
:diffs
]
=
project
.
repo
.
diff
(
last
.
id
,
first
.
id
)
rescue
[]
result
[
:commit
]
=
Commit
.
new
(
first
)
end
result
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment