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
3095ac0c
Commit
3095ac0c
authored
Oct 27, 2016
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make internal api work with full repo path instead of name
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
b5797168
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
4 deletions
+14
-4
internal.rb
lib/api/internal.rb
+14
-4
No files found.
lib/api/internal.rb
View file @
3095ac0c
...
...
@@ -17,15 +17,25 @@ module API
#
helpers
do
def
project_path
@project_path
||=
begin
project_path
=
params
[
:project
].
sub
(
/\.git\z/
,
''
)
Gitlab
.
config
.
repositories
.
storages
.
each
do
|
_
,
storage_path
|
project_path
.
sub!
(
storage_path
,
''
)
end
project_path
end
end
def
wiki?
@wiki
||=
p
arams
[
:project
]
.
end_with?
(
'.wiki'
)
&&
!
Project
.
find_with_namespace
(
p
arams
[
:project
]
)
@wiki
||=
p
roject_path
.
end_with?
(
'.wiki'
)
&&
!
Project
.
find_with_namespace
(
p
roject_path
)
end
def
project
@project
||=
begin
project_path
=
params
[
:project
]
# Check for *.wiki repositories.
# Strip out the .wiki from the pathname before finding the
# project. This applies the correct project permissions to
...
...
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