blacklight_iiif_search 0.0.1.pre.alpha → 0.0.2.pre.alpha
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d1e1ea219c0c4524e390a7fb168f5de14706fcdb
|
4
|
+
data.tar.gz: ab756eb8e3e54f7fbe472952db34a6904c17e128
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fc3d6e2ac52a8e15e6f41f3485b38c0fca3398d29ffcaf20ca1df626e9e5601aab8bff7087082b7bee27be8cf4101ce6075c9b0a3cf0cfdaf07476bcc491a10c
|
7
|
+
data.tar.gz: 955e58b2366489a9aac419f86021aaaca64e5593cdc186753e3d41919782d847a7f0286d2392eb17f35175c0a77797d865a6b639cb92c0a4c2d8fb89384e3587
|
@@ -16,13 +16,12 @@ module BlacklightIiifSearch
|
|
16
16
|
# Update the blacklight catalog controller
|
17
17
|
def inject_catalog_controller_behavior
|
18
18
|
return if IO.read("app/controllers/#{controller_name}_controller.rb").include?('BlacklightIiifSearch')
|
19
|
-
marker = 'include Blacklight::Catalog'
|
20
|
-
insert_into_file "app/controllers/#{controller_name}_controller.rb", after: marker do
|
21
|
-
"\n\n # CatalogController-scope behavior and configuration for BlacklightIiifSearch
|
22
|
-
include BlacklightIiifSearch::Controller"
|
23
|
-
end
|
24
19
|
marker = 'configure_blacklight do |config|'
|
25
|
-
|
20
|
+
inject_into_file "app/controllers/#{controller_name}_controller.rb", before: marker do
|
21
|
+
"\n # CatalogController-scope behavior and configuration for BlacklightIiifSearch
|
22
|
+
include BlacklightIiifSearch::Controller\n\n"
|
23
|
+
end
|
24
|
+
inject_into_file "app/controllers/#{controller_name}_controller.rb", after: marker do
|
26
25
|
"\n\n # configuration for Blacklight IIIF Content Search
|
27
26
|
config.iiif_search = {
|
28
27
|
full_text_field: 'text',
|
@@ -12,7 +12,7 @@ module BlacklightIiifSearch
|
|
12
12
|
def inject_iiif_search_routes
|
13
13
|
unless IO.read('config/routes.rb').include?('BlacklightIiifSearch::Routes')
|
14
14
|
marker = 'Rails.application.routes.draw do'
|
15
|
-
|
15
|
+
inject_into_file 'config/routes.rb', after: marker do
|
16
16
|
"\n\n concern :iiif_search, BlacklightIiifSearch::Routes.new"
|
17
17
|
end
|
18
18
|
# for blacklight_range_limit
|
@@ -11,7 +11,7 @@ module BlacklightIiifSearch
|
|
11
11
|
def inject_iiif_suggest_solrconfig
|
12
12
|
unless IO.read('solr/conf/solrconfig.xml').include?('iiif_suggest')
|
13
13
|
marker = '</config>'
|
14
|
-
|
14
|
+
inject_into_file 'solr/conf/solrconfig.xml', before: marker do
|
15
15
|
" <!-- BEGIN Blacklight IIIF Search autocomplete config -->
|
16
16
|
<!-- solr-tokenizing_suggester is necessary to return single terms from the suggester -->
|
17
17
|
<lib dir=\"${solr.install.dir:../../../..}/contrib\" regex=\"solr-tokenizing_suggester-7.x.jar\" />\n
|
@@ -46,7 +46,7 @@ module BlacklightIiifSearch
|
|
46
46
|
filepath = 'solr/conf/schema.xml'
|
47
47
|
unless IO.read(filepath).include?('iiif_suggest')
|
48
48
|
field_type_marker = '</types>'
|
49
|
-
|
49
|
+
inject_into_file filepath, before: field_type_marker do
|
50
50
|
"\n <!-- BEGIN Blacklight IIIF Search autocomplete config -->
|
51
51
|
<fieldType name=\"textSuggestTokenizer\" class=\"solr.TextField\" positionIncrementGap=\"100\">
|
52
52
|
<analyzer>
|
@@ -64,14 +64,14 @@ module BlacklightIiifSearch
|
|
64
64
|
end
|
65
65
|
|
66
66
|
fields_marker = '</fields>'
|
67
|
-
|
67
|
+
inject_into_file filepath, before: fields_marker do
|
68
68
|
" <!-- BEGIN Blacklight IIIF Search autocomplete config -->
|
69
69
|
<field name=\"iiif_suggest\" type=\"textSuggest\" indexed=\"true\" stored=\"true\" multiValued=\"true\" />
|
70
70
|
<!-- END Blacklight IIIF Search autocomplete config -->\n\n"
|
71
71
|
end
|
72
72
|
|
73
73
|
copy_marker = '</schema>'
|
74
|
-
|
74
|
+
inject_into_file filepath, before: copy_marker do
|
75
75
|
" <!-- BEGIN Blacklight IIIF Search autocomplete config -->
|
76
76
|
<copyField source=\"text\" dest=\"iiif_suggest\"/>
|
77
77
|
<!-- END Blacklight IIIF Search autocomplete config -->\n\n"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: blacklight_iiif_search
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2.pre.alpha
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eben English
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-12-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|