companygardener/lookup_by — pull request #19 by pd (2014-07-07 19:20:45+00:00)
Title: lookup_for scopes: n-arity; name the scope what you want; inverse scoping.

:construction: This should be rebased after #17 hits master; I've merged it in here to ensure support for Rails 3.2+.

This modifies the `lookup_for :foo, scope: ...` behavior to:

1. Only a single scope is defined, which is n-arity. This is backwards incompatible if you previously used the plural form `with_foos`. I could've left it defined, but meh. Pre-1.0!
2. You can now pass `scope: :wudevs` to have your scope named `wudevs`.
3. An additional option `:inverse_scope` is introduced, essentially wrapping `where.not(...)` but with Rails 3 compatibility.