Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
2f35428c
Commit
2f35428c
authored
Aug 11, 2017
by
Sean McGivern
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'gitlab-git-expose-raw-log' into 'master'
Expose the raw_log method See merge request !13434
parents
cfc5f0f5
b21539cc
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
16 deletions
+17
-16
lib/gitlab/git/repository.rb
lib/gitlab/git/repository.rb
+17
-16
No files found.
lib/gitlab/git/repository.rb
View file @
2f35428c
...
...
@@ -324,6 +324,23 @@ module Gitlab
raw_log
(
options
).
map
{
|
c
|
Commit
.
decorate
(
self
,
c
)
}
end
# Used in gitaly-ruby
def
raw_log
(
options
)
actual_ref
=
options
[
:ref
]
||
root_ref
begin
sha
=
sha_from_ref
(
actual_ref
)
rescue
Rugged
::
OdbError
,
Rugged
::
InvalidError
,
Rugged
::
ReferenceError
# Return an empty array if the ref wasn't found
return
[]
end
if
log_using_shell?
(
options
)
log_by_shell
(
sha
,
options
)
else
log_by_walk
(
sha
,
options
)
end
end
def
count_commits
(
options
)
gitaly_migrate
(
:count_commits
)
do
|
is_enabled
|
if
is_enabled
...
...
@@ -733,22 +750,6 @@ module Gitlab
sort_branches
(
branches
,
sort_by
)
end
def
raw_log
(
options
)
actual_ref
=
options
[
:ref
]
||
root_ref
begin
sha
=
sha_from_ref
(
actual_ref
)
rescue
Rugged
::
OdbError
,
Rugged
::
InvalidError
,
Rugged
::
ReferenceError
# Return an empty array if the ref wasn't found
return
[]
end
if
log_using_shell?
(
options
)
log_by_shell
(
sha
,
options
)
else
log_by_walk
(
sha
,
options
)
end
end
def
log_using_shell?
(
options
)
options
[
:path
].
present?
||
options
[
:disable_walk
]
||
...
...
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