Rack::Rewrite 1.0.0 Released

Rack::Rewrite 1.0.0 has just been released. To install simply run: gem install rack-rewrite.

Rack::Rewrite is a web-server agnostic rack middleware for defining and applying rewrite rules. In many cases you can get away with Rack::Rewrite instead of writing Apache mod_rewrite rules.

Documentation is hosted at RubyForge. The source code is hosted at GitHub.

Updates include:


  • Fix rack 1.1.0 / rails3 compatibility by eliminating reliance on REQUEST_URI env param. Paths are now constructed with PATH_INFO and QUERY_STRING
  • Follow rack directory/require convention: require 'rack/rewrite' instead of 'rack-rewrite'
  • Include an HTML anchor tag linked to where the URL being redirected to in the body of 301's and 302's

Check out our other articles on API:

API Development: Turning Controller Actions into Services

What Makes a Good API?