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
e07da598
Commit
e07da598
authored
Jan 26, 2015
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
SEtup new routes for creating and changing repository files
parent
59b08942
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
5 deletions
+8
-5
routes.rb
config/routes.rb
+8
-5
No files found.
config/routes.rb
View file @
e07da598
...
...
@@ -211,17 +211,20 @@ Gitlab::Application.routes.draw do
end
scope
module: :projects
do
# Blob routes:
get
'/new/:id'
,
to:
'blob#new'
,
constraints:
{
id:
/.+/
},
as:
'new_blob'
post
'/create/:id'
,
to:
'blob#create'
,
constraints:
{
id:
/.+/
},
as:
'create_blob'
get
'/edit/:id'
,
to:
'blob#edit'
,
constraints:
{
id:
/.+/
},
as:
'edit_blob'
put
'/update/:id'
,
to:
'blob#update'
,
constraints:
{
id:
/.+/
},
as:
'update_blob'
post
'/preview/:id'
,
to:
'blob#preview'
,
constraints:
{
id:
/.+/
},
as:
'preview_blob'
resources
:blob
,
only:
[
:show
,
:destroy
],
constraints:
{
id:
/.+/
,
format:
false
}
do
get
:diff
,
on: :member
end
resources
:raw
,
only:
[
:show
],
constraints:
{
id:
/.+/
}
resources
:tree
,
only:
[
:show
],
constraints:
{
id:
/.+/
,
format:
/(html|js)/
}
resources
:edit_tree
,
only:
[
:show
,
:update
],
constraints:
{
id:
/.+/
},
path:
'edit'
do
# Cannot be GET to differentiate from GET paths that end in preview.
post
:preview
,
on: :member
end
resource
:avatar
,
only:
[
:show
,
:destroy
]
resources
:new_tree
,
only:
[
:show
,
:update
],
constraints:
{
id:
/.+/
},
path:
'new'
resources
:commit
,
only:
[
:show
],
constraints:
{
id:
/[[:alnum:]]{6,40}/
}
resources
:commits
,
only:
[
:show
],
constraints:
{
id:
/(?:[^.]|\.(?!atom$))+/
,
format:
/atom/
}
resources
:compare
,
only:
[
:index
,
:create
]
...
...
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