Rack::Rewrite 0.2.1 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.
- Implement $& substitution pattern (thanks to Ben Brinckerhoff)
- Ignore empty captures instead of failing during subsitution (thanks to Ben Brinckerhoff)
- Play nice with Rack::Test requests which only set PATH_INFO and not REQUEST_URI (thanks to @docunext)
- Use QUERY_STRING instead of QUERYSTRING as per Rack spec. Closes Issue #1.
Check out our other articles on Rack::Rewrite: