Changesets can be listed by changeset number.
The Git repository is here.
- Revision:
- 385
- Log:
Remove PATH_PREFIX stuff, since Apache+Passenger doesn't need it.
- Author:
- rool
- Date:
- Mon Mar 21 14:15:29 +0000 2011
- Size:
- 4811 Bytes
1 | ActionController::Routing::Routes.draw do |map| |
2 | |
3 | # default |
4 | map.index '/', :controller => 'articles', :action => 'index' |
5 | map.admin '/admin', :controller => 'admin/general', :action => 'index' |
6 | |
7 | # admin/comments controller needs parent article id |
8 | map.connect '/admin/comments/article/:article_id/:action/:id', |
9 | :controller => 'admin/comments', :action => nil, :id => nil |
10 | map.connect '/admin/trackbacks/article/:article_id/:action/:id', |
11 | :controller => 'admin/trackbacks', :action => nil, :id => nil |
12 | map.connect '/admin/content/:action/:id', :controller => 'admin/content' |
13 | |
14 | # make rss feed urls pretty and let them end in .xml |
15 | # this improves caches_page because now apache and webrick will send out the |
16 | # cached feeds with the correct xml mime type. |
17 | map.xml '/xml/itunes/feed.xml', :controller => 'xml', :action => 'itunes' |
18 | map.xml '/xml/articlerss/:id/feed.xml', :controller => 'xml', :action => 'articlerss' |
19 | map.xml '/xml/commentrss/feed.xml', :controller => 'xml', :action => 'commentrss' |
20 | map.xml '/xml/trackbackrss/feed.xml', :controller => 'xml', :action => 'trackbackrss' |
21 | |
22 | map.xml '/xml/:format/feed.xml', :controller => 'xml', :action => 'feed', :type => 'feed' |
23 | map.xml '/xml/:format/:type/feed.xml', :controller => 'xml', :action => 'feed' |
24 | map.xml '/xml/:format/:type/:id/feed.xml', :controller => 'xml', :action => 'feed' |
25 | map.xml '/xml/rss', :controller => 'xml', :action => 'feed', :type => 'feed', :format => 'rss' |
26 | map.xml '/sitemap.xml', :controller => 'xml', :action => 'feed', :format => 'googlesitemap', :type => 'sitemap' |
27 | |
28 | # allow neat perma urls |
29 | map.connect '/articles', |
30 | :controller => 'articles', :action => 'index' |
31 | map.connect '/articles/page/:page', |
32 | :controller => 'articles', :action => 'index', |
33 | :page => /\d+/ |
34 | |
35 | map.connect '/articles/:year/:month/:day', |
36 | :controller => 'articles', :action => 'find_by_date', |
37 | :year => /\d{4}/, :month => /\d{1,2}/, :day => /\d{1,2}/ |
38 | map.connect '/articles/:year/:month', |
39 | :controller => 'articles', :action => 'find_by_date', |
40 | :year => /\d{4}/, :month => /\d{1,2}/ |
41 | map.connect '/articles/:year', |
42 | :controller => 'articles', :action => 'find_by_date', |
43 | :year => /\d{4}/ |
44 | |
45 | map.connect '/articles/:year/:month/:day/page/:page', |
46 | :controller => 'articles', :action => 'find_by_date', |
47 | :year => /\d{4}/, :month => /\d{1,2}/, :day => /\d{1,2}/, :page => /\d+/ |
48 | map.connect '/articles/:year/:month/page/:page', |
49 | :controller => 'articles', :action => 'find_by_date', |
50 | :year => /\d{4}/, :month => /\d{1,2}/, :page => /\d+/ |
51 | map.connect '/articles/:year/page/:page', |
52 | :controller => 'articles', :action => 'find_by_date', |
53 | :year => /\d{4}/, :page => /\d+/ |
54 | |
55 | map.connect '/articles/:year/:month/:day/:title', |
56 | :controller => 'articles', :action => 'permalink', |
57 | :year => /\d{4}/, :day => /\d{1,2}/, :month => /\d{1,2}/ |
58 | |
59 | map.connect '/articles/add_comment/:id', |
60 | :controller => 'articles', :action => 'read_and_comment' |
61 | |
62 | map.connect '/articles/category/:id', |
63 | :controller => 'articles', :action => 'category' |
64 | map.connect '/articles/category/:id/page/:page', |
65 | :controller => 'articles', :action => 'category', |
66 | :page => /\d+/ |
67 | |
68 | map.connect '/articles/tag/:id', |
69 | :controller => 'articles', :action => 'tag' |
70 | map.connect '/articles/tag/:id/page/:page', |
71 | :controller => 'articles', :action => 'tag', |
72 | :page => /\d+/ |
73 | |
74 | map.connect '/pages/*name',:controller => 'articles', :action => 'view_page' |
75 | |
76 | map.connect '/stylesheets/theme/:filename', |
77 | :controller => 'theme', :action => 'stylesheets', :filename => /.*/ |
78 | map.connect '/javascripts/theme/:filename', |
79 | :controller => 'theme', :action => 'javascript', :filename => /.*/ |
80 | map.connect '/images/theme/:filename', |
81 | :controller => 'theme', :action => 'images', :filename => /.*/ |
82 | |
83 | # For the tests |
84 | map.connect '/theme/static_view_test', :controller => 'theme', :action => 'static_view_test' |
85 | |
86 | map.connect '/plugins/filters/:filter/:public_action', |
87 | :controller => 'textfilter', :action => 'public_action' |
88 | |
89 | # Work around the Bad URI bug |
90 | %w{ accounts articles backend files live sidebar textfilter xml }.each do |i| |
91 | map.connect "/#{i}", :controller => "#{i}", :action => 'index' |
92 | map.connect "/#{i}/:action", :controller => "#{i}" |
93 | map.connect "/#{i}/:action/:id", :controller => i, :id => nil |
94 | end |
95 | |
96 | %w{blacklist cache categories comments content feedback general pages |
97 | resources sidebar textfilters themes trackbacks users}.each do |i| |
98 | map.connect "/admin/#{i}", :controller => "admin/#{i}", :action => 'index' |
99 | map.connect "/admin/#{i}/:action/:id", :controller => "admin/#{i}", :action => nil, :id => nil |
100 | end |
101 | |
102 | map.connect '/:controller/:action/:id' |
103 | map.connect '/*from', :controller => 'redirect', :action => 'redirect' |
104 | end |