textacular 5.5.0 → 5.5.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/Gemfile +6 -1
- data/README.md +3 -2
- data/lib/textacular/version.rb +1 -1
- data/lib/textacular.rb +1 -5
- data/spec/{config.travis.yml → config.github.yml} +0 -0
- data/spec/textacular_spec.rb +0 -6
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: eddfcccc0eaadfc3ac88a01770041972e58ec6f15d040fc2edd0d86622b520ac
|
4
|
+
data.tar.gz: 7d726e410c01a0438f57424c051736d8b68df4371f6089794fd5da107fd661e6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b0d0e8a14b67b814d84f1f897a7c4c93fe1c9f3f6be1e9ca4d9749ced7b521c13144e21b06753a4b60620a31c4434828e515e8581c9267aba2794039a8517c8b
|
7
|
+
data.tar.gz: 55591215dc23ed584e9d2117215e4090479c9fd9e0e5cbae20a8f580656b3256bb6fc636228b42682dca461d231a89edf469c067f408bbbaa9bb716842dc9e8b
|
data/CHANGELOG.md
CHANGED
data/Gemfile
CHANGED
@@ -2,7 +2,12 @@ source 'https://rubygems.org'
|
|
2
2
|
|
3
3
|
gemspec
|
4
4
|
|
5
|
-
|
5
|
+
git_source(:github) do |repo_name|
|
6
|
+
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?('/')
|
7
|
+
"https://github.com/#{repo_name}.git"
|
8
|
+
end
|
9
|
+
|
10
|
+
github 'rails/rails', branch: 'main' do
|
6
11
|
gem 'activerecord'
|
7
12
|
end
|
8
13
|
|
data/README.md
CHANGED
@@ -1,10 +1,9 @@
|
|
1
1
|
# textacular
|
2
2
|
[![Gem Version](http://img.shields.io/gem/v/textacular.svg)][rubygems]
|
3
|
-
[![Build Status](https://
|
3
|
+
[![Build Status](https://github.com/textacular/textacular/actions/workflows/main.yml/badge.svg)](https://github.com/textacular/textacular/actions/workflows/main.yml)
|
4
4
|
[![Code Climate](https://img.shields.io/codeclimate/github/textacular/textacular.svg)][codeclimate]
|
5
5
|
|
6
6
|
[rubygems]: http://rubygems.org/gems/textacular
|
7
|
-
[travis]: https://travis-ci.org/textacular/textacular
|
8
7
|
[codeclimate]: https://codeclimate.com/github/textacular/textacular
|
9
8
|
|
10
9
|
Further documentation available at http://textacular.github.com/textacular.
|
@@ -19,6 +18,8 @@ extending ActiveRecord with scopes making search easy and fun!
|
|
19
18
|
## FEATURES/PROBLEMS:
|
20
19
|
|
21
20
|
* Only works with PostgreSQL
|
21
|
+
* Anything that mucks with the `SELECT` statement (notably `pluck`), is likely
|
22
|
+
to [cause problems](https://github.com/textacular/textacular/issues/28).
|
22
23
|
|
23
24
|
|
24
25
|
## SYNOPSIS:
|
data/lib/textacular/version.rb
CHANGED
data/lib/textacular.rb
CHANGED
@@ -124,11 +124,7 @@ module Textacular
|
|
124
124
|
end
|
125
125
|
|
126
126
|
def fuzzy_condition_string(table_name, column, search_term)
|
127
|
-
#
|
128
|
-
search_term = search_term.gsub(/^(['"])/, '\1%')
|
129
|
-
search_term = search_term.gsub(/(['"])$/, '%\1')
|
130
|
-
|
131
|
-
"(#{table_name}.#{column}::text ILIKE #{search_term})"
|
127
|
+
"(#{table_name}.#{column}::text % #{search_term})"
|
132
128
|
end
|
133
129
|
|
134
130
|
|
File without changes
|
data/spec/textacular_spec.rb
CHANGED
@@ -289,12 +289,6 @@ RSpec.describe Textacular do
|
|
289
289
|
end
|
290
290
|
end
|
291
291
|
end
|
292
|
-
|
293
|
-
describe "#fuzzy_search" do
|
294
|
-
it "works if column contains multiple space delimited strings" do
|
295
|
-
expect(GameExtendedWithTextacular.fuzzy_search(title: 'mar')).to eq([mario])
|
296
|
-
end
|
297
|
-
end
|
298
292
|
end
|
299
293
|
end
|
300
294
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: textacular
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.5.
|
4
|
+
version: 5.5.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ben Hamill
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date:
|
14
|
+
date: 2022-01-03 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: pg
|
@@ -154,7 +154,7 @@ files:
|
|
154
154
|
- lib/textacular/tasks.rb
|
155
155
|
- lib/textacular/trigram_installer.rb
|
156
156
|
- lib/textacular/version.rb
|
157
|
-
- spec/config.
|
157
|
+
- spec/config.github.yml
|
158
158
|
- spec/config.yml.example
|
159
159
|
- spec/spec_helper.rb
|
160
160
|
- spec/support/ar_stand_in.rb
|
@@ -200,7 +200,7 @@ specification_version: 4
|
|
200
200
|
summary: Textacular exposes full text search capabilities from PostgreSQL
|
201
201
|
test_files:
|
202
202
|
- spec/config.yml.example
|
203
|
-
- spec/config.
|
203
|
+
- spec/config.github.yml
|
204
204
|
- spec/spec_helper.rb
|
205
205
|
- spec/support/ar_stand_in.rb
|
206
206
|
- spec/support/character.rb
|