Sha256: 27ef2d0571fb081d82d0e03cdb7935b553ee07f7dcc6bfa1d1aa0d81813eb4e9
Contents?: true
Size: 1.67 KB
Versions: 1
Compression:
Stored size: 1.67 KB
Contents
# ActiveRecord::Like [](https://travis-ci.org/ReneB/activerecord-like) [](https://codeclimate.com/github/ReneB/activerecord-like) [](https://gemnasium.com/ReneB/activerecord-like) [](http://badge.fury.io/rb/activerecord-like) An Active Record Plugin that allows chaining a more DSL-style 'like' or 'not-like' query to an ActiveRecord::Base#where. Requires Rails 4 beta or higher. This plugin has been salvaged from the stellar work done by @amatsuda and @claudiob. Most of the code was previously in Active Record master, but was subsequently removed due to, amongst other, scope creep. ## Installation Add this line to your application's Gemfile: gem 'activerecord-like' And then execute: $ bundle Or install it yourself as: $ gem install activerecord-like ## Usage Given a class Post and the WhereChain work in Active Record, this plugin allows code like: Post.where.like(title: "%rails%") and Post.where.not_like(title: "%rails%") ## Contributing 1. Fork it 2. Create your feature branch (`git checkout -b my-new-feature`) 3. Commit your changes (`git commit -am 'Add some feature'`) 4. Make sure the tests run. I will not merge commits that change code without testing the new code. Running the tests is as easy as running `bundle && rake` - if this does not work, consider it a bug and report it. 5. Push to the branch (`git push origin my-new-feature`) 6. Create new Pull Request
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
activerecord-like-0.0.4 | README.md |