gitlab-elasticsearch-git 1.1.1 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG +4 -1
- data/lib/elasticsearch/git/repository.rb +4 -4
- data/lib/elasticsearch/git/version.rb +1 -1
- data/spec/main_spec.rb +7 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 550905668d72d27f4074ab2a6de5e449740d1fb4
|
4
|
+
data.tar.gz: c8ccdb0c3590f912303b846076161fbabb28fb71
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a96fdf7ec58ad80698e8aba72b13036b4bf919581c6f215dda28973f4f05853b26aa49fce19bf828e7cc3870423508041a1bc1230cf5d27cd95cf15eb4cc52fc
|
7
|
+
data.tar.gz: 3da488a15c3968dff44c73f1f376d58dabe8210410dadfaf36f862ea9f8e61be91ac19a7c31ceb2d2032b717aadc98b234a36b3f685affb3055d35d99c70622c
|
data/CHANGELOG
CHANGED
@@ -417,10 +417,10 @@ module Elasticsearch
|
|
417
417
|
query: {
|
418
418
|
bool: {
|
419
419
|
must: [{
|
420
|
-
|
420
|
+
simple_query_string: {
|
421
421
|
fields: fields,
|
422
422
|
query: query,
|
423
|
-
|
423
|
+
default_operator: :or
|
424
424
|
}
|
425
425
|
}]
|
426
426
|
}
|
@@ -478,9 +478,9 @@ module Elasticsearch
|
|
478
478
|
query: {
|
479
479
|
bool: {
|
480
480
|
must: {
|
481
|
-
|
481
|
+
simple_query_string: {
|
482
482
|
query: query,
|
483
|
-
|
483
|
+
default_operator: :and,
|
484
484
|
fields: [ 'blob.content', 'blob.file_name' ]
|
485
485
|
}
|
486
486
|
}
|
data/spec/main_spec.rb
CHANGED
@@ -63,6 +63,13 @@ describe TestRepository do
|
|
63
63
|
expect(found_version_file).to be_truthy
|
64
64
|
end
|
65
65
|
|
66
|
+
it "supports advanced search syntax" do
|
67
|
+
repo.index_blobs
|
68
|
+
TestRepository.__elasticsearch__.refresh_index!
|
69
|
+
|
70
|
+
expect(repo.search('def +(popen | username_regex)')[:blobs][:total_count]).to eq(2)
|
71
|
+
end
|
72
|
+
|
66
73
|
it "indexes specified commits" do
|
67
74
|
repo.index_commits(
|
68
75
|
from_rev: '40f4a7a617393735a95a0bb67b08385bc1e7c66d',
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gitlab-elasticsearch-git
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrey Kumanyaev
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2017-
|
13
|
+
date: 2017-05-03 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: elasticsearch-model
|