Prefix any path in your app with something.
- Converts any incoming path from /foo/xxx to /xxx
- Converts links in body from /xxx to /foo/xxx
As Rails plugin:
rails plugin install git://github.com/grosser/parallel_tests.git
sudo gem install rack-path_prefixer
config.middleware.use('Rack::PathPrefixer', :prefix => 'foo')
The replace links in body part is just a gsub, so it wont cover all cases.
With Rails3 you can use the router to get a similar behaviour with:
# config/routes.rb scope "/foo" do ... all your routes ... end