searchy-json 0.2.0 → 0.3.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9668d156a3f82b6ce35672389d408c2f0d132c3f878c01a78b3ad6187c68cf19
4
- data.tar.gz: ef6ef551f167774a565feef88d57b671d841dc85d60a900a05b2277e9ff60607
3
+ metadata.gz: 4b31d32f50475a1e1e06b6b0503b83b199d590fbe9d02e6a02d2ecc646037d7b
4
+ data.tar.gz: 3da2227dcf3a6810cbdcc196d47d38a78bd6e48b7507a3d98875a8049e388ca2
5
5
  SHA512:
6
- metadata.gz: ea97345d05baf89a8dc32527afa7243acfbf5879fa329937a6352b7b6c4e7f6861d851750e902ac6439a8618bce34316fe9af08d8aefba81e425f3dff62cf166
7
- data.tar.gz: 55350d11a8930fc9e9746015ec80538d75ffe505fefc1f4deef383e09447d9757537c95dad34774279ffc04b38e57cc833dc2c81bc7d68d153b4fea79bf92f7e
6
+ metadata.gz: 1ea1c6822b1c07b7a556d5aa716f669efb44fb7b5111ed5ce68f8629d60a8d8d655eb8c25842ae252fdb6dffd4dc1b71e040b2a15055609cfcb0a23d7e104d5e
7
+ data.tar.gz: ca4dc483e67962698bc439537ffa05947a79b213390155a01710c5db7e8d80b13f8a4759fdfc2d69c156d1ea807af98ee9dba3216b9daf530b817566596e3151
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- searchy (0.1.0)
4
+ searchy-json (0.2.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -45,12 +45,10 @@ PLATFORMS
45
45
  ruby
46
46
 
47
47
  DEPENDENCIES
48
- bundler (~> 1.17)
49
48
  pry (~> 0.12)
50
- rake (~> 10.0)
51
49
  rspec (~> 3.0)
52
50
  rubocop (~> 0.48.0)
53
- searchy!
51
+ searchy-json!
54
52
 
55
53
  BUNDLED WITH
56
54
  1.17.3
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Searchy
1
+ # SearchyJson
2
2
 
3
3
  Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/searchy`. To experiment with that code, run `bin/console` for an interactive prompt.
4
4
 
@@ -40,4 +40,4 @@ The gem is available as open source under the terms of the [MIT License](https:/
40
40
 
41
41
  ## Code of Conduct
42
42
 
43
- Everyone interacting in the Searchy project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/searchy/blob/master/CODE_OF_CONDUCT.md).
43
+ Everyone interacting in the SearchyJson project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/searchy/blob/master/CODE_OF_CONDUCT.md).
data/lib/searchy.rb CHANGED
@@ -5,6 +5,6 @@ require 'searchy/query'
5
5
  require 'searchy/extracter'
6
6
  require 'searchy/service'
7
7
 
8
- module Searchy
8
+ module SearchyJson
9
9
  class Error < StandardError; end
10
10
  end
data/lib/searchy/data.rb CHANGED
@@ -1,4 +1,4 @@
1
- module Searchy
1
+ module SearchyJson
2
2
  class Data
3
3
  attr_reader :data_path, :primary_key, :search_fields, :scope
4
4
 
@@ -1,4 +1,4 @@
1
- module Searchy
1
+ module SearchyJson
2
2
  class Extracter
3
3
  attr_reader :data, :query, :negative_keywords, :positive_keywords, :exact_matches
4
4
 
data/lib/searchy/query.rb CHANGED
@@ -1,4 +1,4 @@
1
- module Searchy
1
+ module SearchyJson
2
2
  class Query
3
3
  attr_reader :text
4
4
 
@@ -1,4 +1,4 @@
1
- module Searchy
1
+ module SearchyJson
2
2
  class Service
3
3
  attr_reader :data_path, :primary_key, :search_fields
4
4
 
@@ -9,14 +9,14 @@ module Searchy
9
9
  end
10
10
 
11
11
  def find(query)
12
- search_query = Searchy::Query.new(query)
12
+ search_query = SearchyJson::Query.new(query)
13
13
  Extracter.new(search_data, search_query).call
14
14
  end
15
15
 
16
16
  private
17
17
 
18
18
  def search_data
19
- @search_data ||= Searchy::Data.new(data_path, primary_key: primary_key, search_fields: search_fields).call
19
+ @search_data ||= SearchyJson::Data.new(data_path, primary_key: primary_key, search_fields: search_fields).call
20
20
  end
21
21
  end
22
22
  end
@@ -1,3 +1,3 @@
1
- module Searchy
2
- VERSION = "0.2.0"
1
+ module SearchyJson
2
+ VERSION = "0.3.0"
3
3
  end
data/searchy.gemspec CHANGED
@@ -5,11 +5,11 @@ require 'searchy/version'
5
5
 
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = 'searchy-json'
8
- spec.version = Searchy::VERSION
8
+ spec.version = SearchyJson::VERSION
9
9
  spec.authors = ['bezrukavyi']
10
10
  spec.email = ['yaroslav.bezrukavyi@gmail.com']
11
11
 
12
- spec.summary = 'Searchy Json'
12
+ spec.summary = 'SearchyJson Json'
13
13
  spec.description = 'Search in JSON file'
14
14
  spec.homepage = 'https://github.com/bezrukavyi/searchy-json'
15
15
  spec.license = 'MIT'
@@ -1,9 +1,9 @@
1
- RSpec.describe Searchy::Service do
1
+ RSpec.describe SearchyJson::Service do
2
2
  let!(:data_path) { File.join(File.dirname(__FILE__), '../../spec/fixtures/data.json') }
3
3
  let!(:primary_key) { 'Name' }
4
4
  let!(:search_fields) { ['Name', 'Type', 'Designed by'] }
5
5
 
6
- subject { Searchy::Service.new(data_path: data_path, primary_key: primary_key, search_fields: search_fields) }
6
+ subject { SearchyJson::Service.new(data_path: data_path, primary_key: primary_key, search_fields: search_fields) }
7
7
 
8
8
  describe '#find' do
9
9
  context 'Support reverse keywords' do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: searchy-json
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - bezrukavyi
@@ -77,7 +77,6 @@ files:
77
77
  - lib/searchy/query.rb
78
78
  - lib/searchy/service.rb
79
79
  - lib/searchy/version.rb
80
- - searchy-json-0.1.0.gem
81
80
  - searchy.gemspec
82
81
  - spec/fixtures/data.json
83
82
  - spec/searchy/service_spec.rb
@@ -104,5 +103,5 @@ requirements: []
104
103
  rubygems_version: 3.0.3
105
104
  signing_key:
106
105
  specification_version: 4
107
- summary: Searchy Json
106
+ summary: SearchyJson Json
108
107
  test_files: []
Binary file