findable 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: cd0c4843a980a02496e5e1b55e9466bd8755e968
4
+ data.tar.gz: e29742dc9478c09cccc03f868632b87abb367f66
5
+ SHA512:
6
+ metadata.gz: 36948d3d3c45ff724706eeda3a35a368b83de3ebfe864c373b757ddadbae7467b4adce1ee2b55268ef2dd45b9f6db34d46a1472488ce4b5c3f40219f64deee11
7
+ data.tar.gz: 9d6d5d7e35b5cac170372ea0f549a82223aaec5cd33ffc02d74248766ca9ef5ecab66962255408e051ba7944a76489a9ede08d85015c4a5ec8451dfee8ebf548
data/.gitignore ADDED
@@ -0,0 +1,16 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
10
+ *.bundle
11
+ *.so
12
+ *.o
13
+ *.a
14
+ mkmf.log
15
+ .DS_Store
16
+
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in findable.gemspec
4
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2015 i2bskn
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,32 @@
1
+ # Findable
2
+
3
+ TODO: Write a gem description
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ ```ruby
10
+ gem 'findable'
11
+ ```
12
+
13
+ And then execute:
14
+
15
+ $ bundle
16
+
17
+ Or install it yourself as:
18
+
19
+ $ gem install findable
20
+
21
+ ## Usage
22
+
23
+ TODO: Write usage instructions here
24
+
25
+ ## Contributing
26
+
27
+ 1. Fork it ( https://github.com/i2bskn/findable/fork )
28
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
29
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
30
+ 4. Push to the branch (`git push origin my-new-feature`)
31
+ 5. Create a new Pull Request
32
+
data/Rakefile ADDED
@@ -0,0 +1,10 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+
4
+ desc "Run all specs"
5
+ RSpec::Core::RakeTask.new(:spec) do |spec|
6
+ spec.pattern = FileList['spec/**/*_spec.rb']
7
+ end
8
+
9
+ task :default => :spec
10
+
data/findable.gemspec ADDED
@@ -0,0 +1,31 @@
1
+ lib = File.expand_path('../lib', __FILE__)
2
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
+ require 'findable/version'
4
+
5
+ Gem::Specification.new do |spec|
6
+ spec.name = "findable"
7
+ spec.version = Findable::VERSION
8
+ spec.authors = ["i2bskn"]
9
+ spec.email = ["i2bskn@gmail.com"]
10
+ spec.summary = %q{Static model to behave like ActiveRecord.}
11
+ spec.description = %q{Static model to behave like ActiveRecord.}
12
+ spec.homepage = "https://github.com/i2bskn/findable"
13
+ spec.license = "MIT"
14
+
15
+ spec.files = `git ls-files -z`.split("\x0")
16
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
17
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
18
+ spec.require_paths = ["lib"]
19
+
20
+ spec.add_dependency "activesupport"
21
+ spec.add_dependency "activemodel"
22
+ spec.add_dependency "redis"
23
+ spec.add_dependency "oj"
24
+
25
+ spec.add_development_dependency "bundler", "~> 1.7"
26
+ spec.add_development_dependency "rake", "~> 10.0"
27
+ spec.add_development_dependency "rspec-rails"
28
+ spec.add_development_dependency "simplecov"
29
+ spec.add_development_dependency "coveralls"
30
+ end
31
+
data/lib/findable.rb ADDED
@@ -0,0 +1,12 @@
1
+ require "active_support"
2
+ require "active_model"
3
+ require "redis"
4
+ require "oj"
5
+
6
+ require "findable/version"
7
+ require "findable/errors"
8
+ require "findable/configuration"
9
+ require "findable/serializer"
10
+ require "findable/base"
11
+ require "findable/railtie" if defined?(Rails)
12
+
@@ -0,0 +1,134 @@
1
+ require "findable/recordable"
2
+ require "findable/connection"
3
+ require "findable/namespace"
4
+
5
+ module Findable
6
+ class Base
7
+ include ActiveModel::Model
8
+ include Recordable
9
+ include Connection
10
+ include Namespace
11
+
12
+ class << self
13
+ def primary_key
14
+ "id"
15
+ end
16
+
17
+ def column_names
18
+ raise NotImplementedError
19
+ end
20
+
21
+ def all
22
+ all_data.map {|data| new(data) }
23
+ end
24
+
25
+ def find(*ids)
26
+ ids = ids.first if ids.size == 1
27
+ values = find_by_id(ids)
28
+
29
+ case
30
+ when values.empty? then nil
31
+ when ids.is_a?(Array) then values.map {|val| new(val)}
32
+ else new(values.first)
33
+ end
34
+ end
35
+
36
+ def find_by(params)
37
+ params.symbolize_keys!
38
+ if id = params.delete(:id)
39
+ values = find_by_id(id)
40
+ return nil if values.empty?
41
+ return new(values.first) if params.empty?
42
+
43
+ values.each {|val|
44
+ record = new(val)
45
+ return record if params.all? {|k,v| record.send(k) == v }
46
+ }
47
+ else
48
+ all_data.each {|val|
49
+ record = new(val)
50
+ return record if params.all? {|k,v| record.send(k) == v }
51
+ }
52
+ end
53
+ end
54
+
55
+ def where(params)
56
+ all.select {|record| params.all? {|k,v| record.send(k) == v } }
57
+ end
58
+
59
+ def exists?(record)
60
+ if record.is_a?(self)
61
+ _id = record.id
62
+ return false unless _id
63
+ else
64
+ _id = record.to_i
65
+ end
66
+
67
+ redis.hexists data_key, _id
68
+ end
69
+
70
+ delegate :first, :last, to: :all
71
+
72
+ def count
73
+ redis.hlen(data_key)
74
+ end
75
+
76
+ def ids
77
+ redis.hkeys(data_key).map(&:to_i)
78
+ end
79
+
80
+ def create(attrs = {})
81
+ record = new(attrs)
82
+ record.save
83
+ record
84
+ end
85
+
86
+ def create!(attrs = {})
87
+ record = new(attrs)
88
+ record.save!
89
+ record
90
+ end
91
+
92
+ def delete_all
93
+ redis.del(data_key)
94
+ end
95
+ alias_method :destroy_all, :delete_all
96
+
97
+ def transaction(&block)
98
+ redis.multi &block
99
+ end
100
+
101
+ def import(records)
102
+ data = records.each_with_object([]) {|record, obj|
103
+ record.id ||= auto_incremented_id
104
+ obj << record.id
105
+ obj << record.to_json
106
+ }
107
+ redis.hmset(data_key, *data)
108
+ end
109
+
110
+ def insert(record)
111
+ record.id ||= auto_incremented_id
112
+ redis.hset(data_key, record.id, record.to_json)
113
+ end
114
+
115
+ def delete(id)
116
+ redis.hdel(data_key, id)
117
+ end
118
+
119
+ private
120
+ def auto_incremented_id
121
+ redis.hincrby(info_key, :auto_inclement, 1)
122
+ end
123
+
124
+ def all_data
125
+ redis.hvals(data_key)
126
+ end
127
+
128
+ def find_by_id(id)
129
+ redis.hmget(data_key, *Array(id)).compact
130
+ end
131
+ end
132
+ end
133
+ end
134
+
@@ -0,0 +1,46 @@
1
+ module Findable
2
+ class Configuration
3
+ VALID_OPTIONS = [
4
+ :redis_options,
5
+ :seed_file
6
+ ].freeze
7
+
8
+ attr_accessor *VALID_OPTIONS
9
+
10
+ def initialize
11
+ reset
12
+ end
13
+
14
+ def configure
15
+ yield self
16
+ end
17
+
18
+ def merge(params)
19
+ self.dup.merge!(params)
20
+ end
21
+
22
+ def merge!(params)
23
+ params.keys.each {|key| self.send("#{key}=", params[key]) }
24
+ self
25
+ end
26
+
27
+ def reset
28
+ self.redis_options = nil
29
+ self.seed_file = defined?(Rails) ? Rails.root.join("db", "findable_seeds.rb") : nil
30
+ end
31
+
32
+ module Accessible
33
+ def configure(options = {}, &block)
34
+ config.merge!(options) unless options.empty?
35
+ config.configure(&block) if block_given?
36
+ end
37
+
38
+ def config
39
+ @_config ||= Configuration.new
40
+ end
41
+ end
42
+ end
43
+
44
+ extend Configuration::Accessible
45
+ end
46
+
@@ -0,0 +1,25 @@
1
+ module Findable
2
+ module Connection
3
+ extend ActiveSupport::Concern
4
+
5
+ module ClassMethods
6
+ def redis
7
+ @_redis ||= generate_redis_connection!
8
+ end
9
+
10
+ private
11
+ def generate_redis_connection!
12
+ redis_options ? Redis.new(*redis_options) : Redis.current
13
+ end
14
+
15
+ def redis_options
16
+ Findable.config.redis_options.presence
17
+ end
18
+ end
19
+
20
+ def redis
21
+ self.class.redis
22
+ end
23
+ end
24
+ end
25
+
@@ -0,0 +1,5 @@
1
+ module Findable
2
+ class FindableError < StandardError; end
3
+ class RecordNotFound < FindableError; end
4
+ end
5
+
@@ -0,0 +1,23 @@
1
+ module Findable
2
+ module Namespace
3
+ extend ActiveSupport::Concern
4
+
5
+ module ClassMethods
6
+ def info_key
7
+ namespace[:info]
8
+ end
9
+
10
+ def data_key
11
+ namespace[:data]
12
+ end
13
+
14
+ private
15
+ def namespace
16
+ %i(info data).each_with_object({}) do |name, obj|
17
+ obj[name] = [self.model_name.plural, name].join(":")
18
+ end
19
+ end
20
+ end
21
+ end
22
+ end
23
+
@@ -0,0 +1,8 @@
1
+ module Findable
2
+ class Railtie < ::Rails::Railtie
3
+ rake_tasks do
4
+ load "tasks/findable.rake"
5
+ end
6
+ end
7
+ end
8
+
@@ -0,0 +1,93 @@
1
+ module Findable
2
+ module Recordable
3
+ extend ActiveSupport::Concern
4
+ include Serializer
5
+
6
+ included do
7
+ include ActiveModel::AttributeMethods
8
+
9
+ attribute_method_suffix "="
10
+ attribute_method_suffix "?"
11
+ end
12
+
13
+ module ClassMethods
14
+ def field(attr, options={})
15
+ options.symbolize_keys!
16
+ define_accessor(attr.to_sym, options)
17
+ end
18
+
19
+ def fields(*args)
20
+ options = args.extract_options!
21
+ args.each {|arg| field(arg, options) }
22
+ end
23
+
24
+ private
25
+ def define_accessor(attr, options)
26
+ unless public_method_defined?(attr)
27
+ define_attribute_methods attr
28
+ define_method attr do
29
+ attributes[attr]
30
+ end
31
+ end
32
+ end
33
+ end
34
+
35
+ def initialize(params={})
36
+ params = deserialize(params) if params.is_a?(String)
37
+ params.symbolize_keys!
38
+ params.keys.each {|attr| self.class.field(attr) }
39
+ @_attributes = params
40
+ end
41
+
42
+ def id
43
+ attributes[:id].presence || nil
44
+ end
45
+ # alias_method :quoted_id, :id
46
+
47
+ def id=(_id)
48
+ attributes[:id] = _id
49
+ end
50
+
51
+ def save
52
+ self.class.insert(self)
53
+ end
54
+ alias_method :save!, :save
55
+
56
+ def delete
57
+ self.class.delete(id)
58
+ end
59
+ alias_method :destroy, :delete
60
+
61
+ def new_record?
62
+ id ? !self.class.exists?(self) : true
63
+ end
64
+
65
+ def persisted?
66
+ !new_record?
67
+ end
68
+
69
+ def to_json(methods: nil)
70
+ _attrs = attributes.dup
71
+ _attrs.merge!(methods.to_sym => self.send(methods)) if methods
72
+ serialize(_attrs)
73
+ end
74
+
75
+ def hash
76
+ id.hash
77
+ end
78
+
79
+ def attributes
80
+ @_attributes ||= {}
81
+ end
82
+
83
+ private
84
+ def attribute=(attr, val)
85
+ attributes[attr.to_sym] = val
86
+ end
87
+
88
+ def attribute?(attr)
89
+ attributes[attr.to_sym].present?
90
+ end
91
+ end
92
+ end
93
+
@@ -0,0 +1,12 @@
1
+ module Findable
2
+ module Serializer
3
+ def serialize(string)
4
+ Oj.dump(string)
5
+ end
6
+
7
+ def deserialize(string)
8
+ Oj.load(string)
9
+ end
10
+ end
11
+ end
12
+
@@ -0,0 +1,3 @@
1
+ module Findable
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1,14 @@
1
+ module Findable
2
+ module Generators
3
+ class InstallGenerator < ::Rails::Generators::Base
4
+ source_root File.expand_path(File.join(File.dirname(__FILE__), "templates"))
5
+
6
+ desc "Install Findable files"
7
+ def install_findable_files
8
+ template "seeds.rb", "db/findable_seeds.rb"
9
+ template "findable.rb", "config/initializers/findable.rb"
10
+ end
11
+ end
12
+ end
13
+ end
14
+
@@ -0,0 +1,8 @@
1
+ Findable.configure do |config|
2
+ # Redis connection setting. (default: `Redis.current`)
3
+ # config.redis_options = {host: "localhost", port: 6379, db: 2}
4
+
5
+ # Seed file of Findable
6
+ # config.seed_file = Rails.root.join("db", "findable_seeds.rb")
7
+ end
8
+
@@ -0,0 +1,2 @@
1
+ # Seed file of Findable
2
+
@@ -0,0 +1,9 @@
1
+ namespace :findable do
2
+ desc "Load seed file of findable."
3
+ task :seed => :environment do
4
+ if Findable.config.seed_file
5
+ load Findable.config.seed_file
6
+ end
7
+ end
8
+ end
9
+
File without changes
@@ -0,0 +1,5 @@
1
+ require "spec_helper"
2
+
3
+ describe Findable::Base do
4
+ end
5
+
@@ -0,0 +1,67 @@
1
+ require "spec_helper"
2
+
3
+ describe Findable::Configuration do
4
+ let(:storage) { :memory }
5
+ let(:redis) { {host: "localhost", port: 6379, db: 15} }
6
+
7
+ describe "#initialize" do
8
+ subject { Findable.config }
9
+
10
+ # defined options
11
+ Findable::Configuration::VALID_OPTIONS.each do |key|
12
+ it { is_expected.to respond_to(key) }
13
+ end
14
+
15
+ # default settings
16
+ it { is_expected.to have_attributes(default_storage: :redis) }
17
+ it { is_expected.to have_attributes(redis_options: nil) }
18
+ end
19
+
20
+ describe "#merge" do
21
+ subject { Findable.config.merge(default_storage: storage) }
22
+
23
+ it { is_expected.to have_attributes(default_storage: storage) }
24
+ it { is_expected.to be_kind_of(Findable::Configuration) }
25
+ end
26
+
27
+ describe "#merge!" do
28
+ subject { Findable.config.merge!(default_storage: storage) }
29
+
30
+ it { is_expected.to have_attributes(default_storage: storage) }
31
+ it { is_expected.to be_kind_of(Findable::Configuration) }
32
+ end
33
+
34
+ describe "Accessible" do
35
+ context "extended" do
36
+ subject { Module.new { extend Findable::Configuration::Accessible } }
37
+
38
+ it { is_expected.to respond_to(:configure) }
39
+ it { is_expected.to respond_to(:config) }
40
+ end
41
+
42
+ describe "#configure" do
43
+ before do
44
+ Findable.configure do |config|
45
+ config.default_storage = storage
46
+ config.redis_options = redis
47
+ end
48
+ end
49
+
50
+ subject { Findable.config }
51
+
52
+ it { is_expected.to have_attributes(default_storage: storage) }
53
+ it { is_expected.to have_attributes(redis_options: redis) }
54
+
55
+ it {
56
+ expect {
57
+ Findable.configure {|config| config.unknown = :value }
58
+ }.to raise_error
59
+ }
60
+ end
61
+
62
+ describe "#config" do
63
+ it { expect(Findable.config.is_a?(Findable::Configuration)).to be_truthy }
64
+ end
65
+ end
66
+ end
67
+
@@ -0,0 +1,22 @@
1
+ require "simplecov"
2
+ require "coveralls"
3
+ Coveralls.wear!
4
+
5
+ SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
6
+ SimpleCov::Formatter::HTMLFormatter,
7
+ Coveralls::SimpleCov::Formatter
8
+ ]
9
+
10
+ SimpleCov.start do
11
+ add_filter "spec"
12
+ add_filter ".bundle"
13
+ end
14
+
15
+ require "findable"
16
+
17
+ Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
18
+
19
+ RSpec.configure do |config|
20
+ config.after(:each) { Findable.config.reset }
21
+ end
22
+
File without changes
metadata ADDED
@@ -0,0 +1,200 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: findable
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - i2bskn
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2015-01-12 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: activesupport
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: activemodel
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: redis
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: oj
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :runtime
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: bundler
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '1.7'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '1.7'
83
+ - !ruby/object:Gem::Dependency
84
+ name: rake
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - "~>"
88
+ - !ruby/object:Gem::Version
89
+ version: '10.0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - "~>"
95
+ - !ruby/object:Gem::Version
96
+ version: '10.0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: rspec-rails
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: simplecov
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
125
+ - !ruby/object:Gem::Dependency
126
+ name: coveralls
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - ">="
130
+ - !ruby/object:Gem::Version
131
+ version: '0'
132
+ type: :development
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - ">="
137
+ - !ruby/object:Gem::Version
138
+ version: '0'
139
+ description: Static model to behave like ActiveRecord.
140
+ email:
141
+ - i2bskn@gmail.com
142
+ executables: []
143
+ extensions: []
144
+ extra_rdoc_files: []
145
+ files:
146
+ - ".gitignore"
147
+ - Gemfile
148
+ - LICENSE.txt
149
+ - README.md
150
+ - Rakefile
151
+ - findable.gemspec
152
+ - lib/findable.rb
153
+ - lib/findable/base.rb
154
+ - lib/findable/configuration.rb
155
+ - lib/findable/connection.rb
156
+ - lib/findable/errors.rb
157
+ - lib/findable/namespace.rb
158
+ - lib/findable/railtie.rb
159
+ - lib/findable/recordable.rb
160
+ - lib/findable/serializer.rb
161
+ - lib/findable/version.rb
162
+ - lib/generators/findable/install_generator.rb
163
+ - lib/generators/findable/templates/findable.rb
164
+ - lib/generators/findable/templates/seeds.rb
165
+ - lib/tasks/findable.rake
166
+ - spec/findable/.keep
167
+ - spec/findable/base_spec.rb
168
+ - spec/findable/configuration_spec.rb
169
+ - spec/spec_helper.rb
170
+ - spec/support/.keep
171
+ homepage: https://github.com/i2bskn/findable
172
+ licenses:
173
+ - MIT
174
+ metadata: {}
175
+ post_install_message:
176
+ rdoc_options: []
177
+ require_paths:
178
+ - lib
179
+ required_ruby_version: !ruby/object:Gem::Requirement
180
+ requirements:
181
+ - - ">="
182
+ - !ruby/object:Gem::Version
183
+ version: '0'
184
+ required_rubygems_version: !ruby/object:Gem::Requirement
185
+ requirements:
186
+ - - ">="
187
+ - !ruby/object:Gem::Version
188
+ version: '0'
189
+ requirements: []
190
+ rubyforge_project:
191
+ rubygems_version: 2.2.2
192
+ signing_key:
193
+ specification_version: 4
194
+ summary: Static model to behave like ActiveRecord.
195
+ test_files:
196
+ - spec/findable/.keep
197
+ - spec/findable/base_spec.rb
198
+ - spec/findable/configuration_spec.rb
199
+ - spec/spec_helper.rb
200
+ - spec/support/.keep