Does anyone have a Rake task to find the routes generated by Si开发者_如何学JAVAnatra?
Take a look at Sinatra::Base.routes
. With those information you can easily generate the rake-task.
Update: There's a sinatra-rake-routes gem you could check.
Sinatra doesn't generate routes like Rails does. You need to define them yourself:
http://www.sinatrarb.com/intro#Routes
精彩评论