Commit a21abce94f25d24b48c038e4a36974735a5b7149
1 parent
bde50885
Exists in
master
and in
4 other branches
Add tree-ish route placeholders, modify commit(s) routes
Showing
1 changed file
with
11 additions
and
1 deletions
Show diff stats
config/routes.rb
@@ -182,7 +182,10 @@ Gitlab::Application.routes.draw do | @@ -182,7 +182,10 @@ Gitlab::Application.routes.draw do | ||
182 | get :test | 182 | get :test |
183 | end | 183 | end |
184 | end | 184 | end |
185 | - resources :commits do | 185 | + |
186 | + resources :commit, only: [:show], constraints: {id: /[[:alnum:]]{6,40}/} | ||
187 | + | ||
188 | + resources :commits, only: [:index, :show] do | ||
186 | collection do | 189 | collection do |
187 | get :compare | 190 | get :compare |
188 | end | 191 | end |
@@ -191,6 +194,7 @@ Gitlab::Application.routes.draw do | @@ -191,6 +194,7 @@ Gitlab::Application.routes.draw do | ||
191 | get :patch | 194 | get :patch |
192 | end | 195 | end |
193 | end | 196 | end |
197 | + | ||
194 | resources :team, controller: 'team_members', only: [:index] | 198 | resources :team, controller: 'team_members', only: [:index] |
195 | resources :team_members | 199 | resources :team_members |
196 | resources :milestones | 200 | resources :milestones |
@@ -208,6 +212,12 @@ Gitlab::Application.routes.draw do | @@ -208,6 +212,12 @@ Gitlab::Application.routes.draw do | ||
208 | post :preview | 212 | post :preview |
209 | end | 213 | end |
210 | end | 214 | end |
215 | + | ||
216 | + # XXX: WIP | ||
217 | + # resources :blame, only: [:show], constraints: {id: /.+/} | ||
218 | + # resources :blob, only: [:show], constraints: {id: /.+/} | ||
219 | + # resources :raw, only: [:show], constraints: {id: /.+/} | ||
220 | + # resources :tree, only: [:show], constraints: {id: /.+/} | ||
211 | end | 221 | end |
212 | 222 | ||
213 | root to: "dashboard#index" | 223 | root to: "dashboard#index" |