algoliasearch-jekyll 0.9.1 → 1.0.0.beta.pre.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (47) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +3 -4
  3. data/CONTRIBUTING.md +8 -1
  4. data/Gemfile +4 -5
  5. data/README.md +318 -11
  6. data/Rakefile +7 -12
  7. data/algoliasearch-jekyll.gemspec +66 -62
  8. data/gemfiles/jekyll_v2.gemfile +3 -3
  9. data/gemfiles/jekyll_v3.gemfile +4 -4
  10. data/gemfiles/jekyll_v3_1_3.gemfile +24 -0
  11. data/gemfiles/jekyll_v3_1_6.gemfile +24 -0
  12. data/lib/algoliasearch-jekyll.rb +1 -3
  13. data/lib/credential_checker.rb +2 -1
  14. data/lib/error_handler.rb +6 -0
  15. data/lib/push.rb +81 -19
  16. data/lib/record_extractor.rb +120 -140
  17. data/lib/utils.rb +13 -0
  18. data/lib/version.rb +1 -1
  19. data/scripts/release +13 -12
  20. data/scripts/test_v3 +1 -1
  21. data/scripts/watch +4 -0
  22. data/spec/error_handler_spec.rb +17 -0
  23. data/spec/fixtures/jekyll_version_2/404.html +8 -0
  24. data/spec/fixtures/jekyll_version_2/404.md +9 -0
  25. data/spec/fixtures/jekyll_version_2/_my-collection/collection-item.md +3 -0
  26. data/spec/fixtures/jekyll_version_2/_posts/2015-07-02-test-post.md +1 -1
  27. data/spec/fixtures/jekyll_version_2/about.md +3 -0
  28. data/spec/fixtures/jekyll_version_2/front_matter.md +15 -0
  29. data/spec/fixtures/jekyll_version_2/index.html +3 -1
  30. data/spec/fixtures/jekyll_version_2/only-divs.md +15 -0
  31. data/spec/fixtures/jekyll_version_2/only-paragraphs.md +15 -0
  32. data/spec/fixtures/jekyll_version_3/404.html +8 -0
  33. data/spec/fixtures/jekyll_version_3/404.md +9 -0
  34. data/spec/fixtures/jekyll_version_3/_config.yml +1 -1
  35. data/spec/fixtures/jekyll_version_3/_my-collection/collection-item.md +3 -0
  36. data/spec/fixtures/jekyll_version_3/_posts/2015-07-02-test-post.md +1 -1
  37. data/spec/fixtures/jekyll_version_3/about.md +3 -0
  38. data/spec/fixtures/jekyll_version_3/front_matter.md +15 -0
  39. data/spec/fixtures/jekyll_version_3/index.html +4 -1
  40. data/spec/fixtures/jekyll_version_3/only-divs.md +15 -0
  41. data/spec/fixtures/jekyll_version_3/only-paragraphs.md +15 -0
  42. data/spec/push_spec.rb +211 -8
  43. data/spec/record_extractor_spec.rb +296 -358
  44. data/spec/spec_helper.rb +32 -11
  45. data/txt/record_too_big +19 -0
  46. metadata +40 -51
  47. data/scripts/watch +0 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d6047d13e0009e3118aa3f92185f4bb75834b30a
4
- data.tar.gz: 9699b92d23a09417e85c436949bba0efd183c9f7
3
+ metadata.gz: 214ae0a5e7ebbc65907d8ad0992d966336752d13
4
+ data.tar.gz: b0bf6063d62e3ed7f340607f509dc2466aa31b83
5
5
  SHA512:
6
- metadata.gz: c21136d528d777aea77bbc62ce0e6ffb92b19ca0a6fa4c090664021814a7d9d61d5796819017fdbcdc582d6c4f96126b5af21afdc4bc8956ffba6926eb9dcbec
7
- data.tar.gz: 46e1225115b202bf4bd110456f219aeb03104853e8b7a358c8bd5a0d38087e1fdbff9c6da74305e649d769c2387eef43ef754e79f7f1e193f639f94c38f01aca
6
+ metadata.gz: 367334786b413eccd82c884d9e2dc116d244b22805ac8b149bb44a2d1a6a2036fbc3e7b8dfdeb8803e973e0aa1cd25e29199d4e44c3b3da84257e7337a7a1485
7
+ data.tar.gz: 303abcbc5b798aca9443fb5ea6605b0e828d21b4ba608c187ef43a46ed82827edceacf5848928b2f30894306606a58a472895f865ec5109554489f43d7e7fa0c
@@ -6,10 +6,9 @@ gemfile:
6
6
  before_script: bundle update
7
7
  script: ./scripts/test_ci
8
8
  rvm:
9
- - 2.4.2
10
- - 2.3.5
11
- - 2.2.5
12
- - 2.1.10
9
+ - 2.2
10
+ - 2.1
11
+ - 2.0
13
12
  notifications:
14
13
  email:
15
14
  on_success: never
@@ -35,8 +35,11 @@ If you want to test the plugin on an existing Jekyll website while developping,
35
35
  I suggest updating the website `Gemfile` to point to the correct local directory
36
36
 
37
37
  ```ruby
38
- gem "algoliasearch-jekyll", :path => "/path/to/local/gem/folder"
38
+ group :jekyll_plugins do
39
+ gem "algoliasearch-jekyll", :path => "/path/to/local/gem/folder"
40
+ end
39
41
  ```
42
+
40
43
  You should also run `rake gemspec` from the `algoliasearch-jekyll` repository if
41
44
  you added/deleted any file or dependency.
42
45
 
@@ -59,5 +62,9 @@ This part is for main contributors:
59
62
  rake install
60
63
  ```
61
64
 
65
+ # Project owner
66
+
67
+ [@pixelastic](https://github.com/pixelastic)
68
+
62
69
 
63
70
 
data/Gemfile CHANGED
@@ -1,14 +1,14 @@
1
1
  source 'http://rubygems.org'
2
2
 
3
- gem 'algoliasearch', '~> 1.12'
3
+ gem 'algoliasearch', '~> 1.4'
4
4
  gem 'appraisal', '~> 2.1.0'
5
5
  gem 'awesome_print', '~> 1.6'
6
- gem 'json', '>= 1.8.6'
7
- gem 'nokogiri', '~> 1.7', '>= 1.7.2'
6
+ gem 'json', '~> 1.8'
7
+ gem 'nokogiri', '~> 1.6'
8
+ gem 'html-hierarchy-extractor', '~> 1.0'
8
9
  gem 'verbal_expressions', '~> 0.1.5'
9
10
 
10
11
  group :development do
11
- gem 'rake', '< 11.0'
12
12
  gem 'coveralls', '~> 0.8'
13
13
  gem 'flay', '~> 2.6'
14
14
  gem 'flog', '~> 4.3'
@@ -17,5 +17,4 @@ group :development do
17
17
  gem 'rspec', '~> 3.0'
18
18
  gem 'rubocop', '~> 0.31'
19
19
  gem 'simplecov', '~> 0.10'
20
- gem "rack", "< 2"
21
20
  end
data/README.md CHANGED
@@ -1,17 +1,324 @@
1
- # Algolia Jekyll Plugin
1
+ # Algolia Jekyll Plugin
2
2
 
3
- ## ⚠ DEPRECATION NOTICE
3
+ [![Gem Version][1]](http://badge.fury.io/rb/algoliasearch-jekyll)
4
+ [![Build Status][2]](https://travis-ci.org/algolia/algoliasearch-jekyll)
5
+ [![Coverage Status][3]](https://coveralls.io/github/algolia/algoliasearch-jekyll?branch=master)
6
+ [![Code Climate][4]](https://codeclimate.com/github/algolia/algoliasearch-jekyll)
7
+ ![Jekyll >= 2.5](https://img.shields.io/badge/jekyll-%3E%3D%202.5-green.svg)
4
8
 
5
- This gem has been deprecated in favor of [jekyll-algolia][1].
9
+ Jekyll plugin to automatically index your Jekyll posts and pages into an
10
+ Algolia index by running `bundle exec jekyll algolia push`.
6
11
 
7
- No further development will be happening on that gem.
12
+ ## Usage
8
13
 
9
- We strongly encourage you to try the new gem. It is officially supported by
10
- Algolia and you can find its [complete documentation][2] online.
14
+ ```shell
15
+ $ bundle exec jekyll algolia push
16
+ ```
11
17
 
12
- <<<<<<< 2ecd95dcf20550d3e43282c6c3e7158130ec2e3d
13
- =======
18
+ This will push the content of your jekyll website to your Algolia index.
14
19
 
15
- >>>>>>> Adding deprecation notice in the readme
16
- [1]: https://github.com/algolia/jekyll-algolia
17
- [2]: https://community.algolia.com/jekyll-algolia/getting-started.html
20
+ You can specify any option you would pass to `jekyll build`, like
21
+ `--config`, `--source`, `--destination`, etc.
22
+
23
+ ## Installation
24
+
25
+ First, add the `algoliasearch-jekyll` gem to your `Gemfile`, in the
26
+ `:jekyll_plugins` section. If you do not yet have a `Gemfile`, here is the
27
+ minimal content to get your started.
28
+
29
+ ```ruby
30
+ source 'https://rubygems.org'
31
+
32
+ gem 'jekyll', '~> 2.5.3'
33
+
34
+ group :jekyll_plugins do
35
+ gem 'algoliasearch-jekyll', '~> 0.7.0'
36
+ end
37
+ ```
38
+
39
+ Once this is done, download all dependencies with `bundle install`.
40
+
41
+ Then, add `algoliasearch-jekyll` to your `_config.yml` file, under the `gems`
42
+ section, like this:
43
+
44
+ ```yaml
45
+ gems:
46
+ - algoliasearch-jekyll
47
+ ```
48
+
49
+ If everything went well, you should be able to run `jekyll help` and see the
50
+ `algolia` subcommand listed.
51
+
52
+ ## Configuration
53
+
54
+ Add information about your Algolia configuration into the `_config.yml` file,
55
+ under the `algolia` section, like this:
56
+
57
+ ```yaml
58
+ algolia:
59
+ application_id: 'your_application_id'
60
+ index_name: 'your_index_name'
61
+ ```
62
+
63
+ You write api key will be read from the `ALGOLIA_API_KEY` environment variable.
64
+ You can define it on the same line as your command, allowing you to type
65
+ `ALGOLIA_API_KEY='your_write_api_key' bundle exec jekyll algolia push`.
66
+
67
+ Note that your API key should have write access to both the `index_name` and
68
+ `_tmp` suffixed version of it (eg. `your_index_name` and `your_index_name_tmp`)
69
+ in the previous example). This is due to the way we do atomic pushes by pushing
70
+ to a temporary index and then renaming it.
71
+
72
+ ### ⚠ Other, unsecure, method ⚠
73
+
74
+ You can also store your write api key in a file named `_algolia_api_key`, in
75
+ your source directory. If you do this we __very, very, very strongly__ encourage
76
+ you to make sure the file is not tracked in your versioning system.
77
+
78
+ ### Options
79
+
80
+ The plugin uses sensible defaults, but you may want to override some of its
81
+ configuration. Here are the options you can add to your `_config.yml`
82
+ file, under the `algolia` section:
83
+
84
+ #### `excluded_files`
85
+
86
+ Defines which files should not be indexed for search.
87
+
88
+ ```yml
89
+ algolia:
90
+ excluded_files:
91
+ - index.html
92
+ - 2015-01-01-post.md
93
+ ```
94
+
95
+ #### `record_css_selector`
96
+
97
+ All HTML nodes matching this CSS Selector will be indexed. Default value is `p`,
98
+ meaning that all `<p>` paragraphs will be indexed.
99
+
100
+ If you would like to also index lists, you could set it like this:
101
+
102
+ ```yml
103
+ algolia:
104
+ record_css_selector: 'p,ul'
105
+ ```
106
+
107
+ #### `lazy_update`
108
+
109
+ `false`: The plugin will push all the records to a temporary index and once
110
+ everything is pushed will override the current index with it. This is the most
111
+ straightforward way and will ensure that all the changes happen in one move. You
112
+ either search in the old data, or in the new data. This is the default value.
113
+
114
+ `true`: With `lazy_update` enabled, the plugin will try to reduce the number of
115
+ calls done to the API, to consume less operations on your quota. It will get
116
+ a list of all the records in your index and all the records ready to be pushed.
117
+ It will compare both and push the new while deleting the old. In most cases it
118
+ should consume less operations, but the changes won't be atomic (ie. you might
119
+ have your index in an hybrid state, with old records not yet removed and/or new
120
+ records not yet added for a couple of minutes).
121
+
122
+ #### `settings`
123
+
124
+ Here you can pass any specific [index settings][5] to your Algolia index. All
125
+ the settings supported by the API can be passed here.
126
+
127
+ ##### Examples
128
+
129
+ If you want to activate `distinct` and some snippets for example, you would do:
130
+
131
+ ```yml
132
+ algolia:
133
+ settings:
134
+ attributeForDistinct: 'hierarchy'
135
+ distinct: true
136
+ attributesToSnippet: ['text:20']
137
+ ```
138
+
139
+ If you want to search in other fields than the default ones, you'll have to edit
140
+ the `attributesToIndex` (default is `%w(title h1 h2 h3 h4 h5 h6 unordered(text)
141
+ unordered(tags))`
142
+
143
+ ```yml
144
+ algolia:
145
+ settings:
146
+ attributesToIndex:
147
+ - title
148
+ - h1
149
+ - h2
150
+ - h3
151
+ - h4
152
+ - h5
153
+ - h6
154
+ - unordered(text)
155
+ - unordered(tags)
156
+ - your_custom_attribute_1
157
+ - your_custom_attribute_2
158
+ - ...
159
+ ```
160
+
161
+ ### Hooks
162
+
163
+ The `AlgoliaSearchRecordExtractor` contains two methods (`custom_hook_each` and
164
+ `custom_hook_all`) that are here so you can overwrite them to add your custom
165
+ logic. By default, they do nothing except returning the argument they take as
166
+ input, and are placeholder for you to override.
167
+
168
+ The best way to override them is to create a `./_plugins/search.rb` file, with
169
+ the following content:
170
+
171
+ ```ruby
172
+ class AlgoliaSearchRecordExtractor
173
+ # Hook to modify a record after extracting
174
+ def custom_hook_each(item, node)
175
+ # `node` is a Nokogiri HTML node, so you can access its type through `node.name`
176
+ # or its classname through `node.attr('class')` for example
177
+
178
+ # Just return `nil` instead of `item` if you want to discard this record
179
+ item
180
+ end
181
+
182
+ # Hook to modify all records after extracting
183
+ def custom_hook_all(items)
184
+ items
185
+ end
186
+ end
187
+ ```
188
+
189
+ The `AlgoliaSearchJekyllPush` class also lets user define the
190
+ `custom_hook_excluded_file?` method. This method is called on every file that
191
+ the plugin thinks it should parse and index. If it returns `true`, the file is
192
+ not indexed. You can add here your custom logic to exclude some files.
193
+
194
+ ```ruby
195
+ class AlgoliaSearchJekyllPush < Jekyll::Command
196
+ class << self
197
+ # Hook to exclude some files from indexing
198
+ def custom_hook_excluded_file?(file)
199
+ return true if filepath =~ %r{^/excluded_dir/}
200
+ false
201
+ end
202
+ end
203
+ end
204
+ ```
205
+
206
+ ## Command line
207
+
208
+ Here is the list of command line options you can pass to the `jekyll algolia
209
+ push` command:
210
+
211
+ | Flag | Description |
212
+ | ---- | ----- |
213
+ | `--config ./_config.yml` | You can here specify the config file to use. Default is `_config.yml` |
214
+ | `--future` | With this flag, the command will also index posts with a future date |
215
+ | `--limit_posts 10` | Limits the number of posts to parse and index |
216
+ | `--drafts` | Index drafts in the `_drafts` folder as well |
217
+ | `--dry-run` or `-n` | Do a dry run, do not actually push anything to your index |
218
+ | `--verbose` | Display more information about what is going to be indexed |
219
+
220
+ ## Dependencies
221
+
222
+ The `algoliasearch-jekyll` plugin works for versions of Jekyll starting from
223
+ 2.5, with a version of Ruby of at least 2.0. You also need
224
+ [Bundler][6] to add the gem as a dependency to Jekyll.
225
+
226
+ ## Searching
227
+
228
+ This plugin will index your data in your Algolia index. Building the front-end
229
+ search is of the scope of this plugin, but you can follow [our tutorials][7] or
230
+ use our forked version of the popular [Hyde theme][8].
231
+
232
+ ## GitHub Pages
233
+
234
+ GitHub does not allow custom plugins to be run on GitHub Pages. This means that
235
+ you'll either have to run `bundle exec jekyll algolia push` manually, or
236
+ configure TravisCI to do it for you.
237
+
238
+ [Travis CI][9] is an hosted continuous integration
239
+ service, and it's free for open-source projects. Properly configured, it can
240
+ automatically reindex your data whenever you push to `gh-pages`.
241
+
242
+ For it to work, you'll have 3 steps to perform.
243
+
244
+ ### 1. Create a `.travis.yml` file
245
+
246
+ Create a file named `.travis.yml` at the root of your project, with the
247
+ following content:
248
+
249
+ ```yml
250
+ language: ruby
251
+ cache: bundler
252
+ branches:
253
+ only:
254
+ - gh-pages
255
+ script:
256
+ - bundle exec jekyll algolia push
257
+ rvm:
258
+ - 2.2
259
+ ```
260
+
261
+ This file will be read by Travis and instruct it to fetch all dependencies
262
+ defined in the `Gemfile`, then run `jekyll algolia push`. This will be
263
+ triggered when data is pushed to the `gh-pages` branch.
264
+
265
+ ### 2. Update your `_config.yml` file to exclude `vendor`
266
+
267
+ Travis will download all you `Gemfile` dependencies into a directory named
268
+ `vendor`. You have to tell Jekyll to ignore this directory, otherwise Jekyll
269
+ will try to parse it (and fail).
270
+
271
+ Doing so is easy, add the following line to your `_config.yml` file:
272
+
273
+ ```yml
274
+ exclude: [vendor]
275
+ ```
276
+
277
+ ### 3. Configure Travis
278
+
279
+ In order for Travis to be able to push data to your index on your behalf, you
280
+ have to give it your write API Key. This is achieved by defining an
281
+ `ALGOLIA_API_KEY` [environment variable][10] in Travis settings.
282
+
283
+ You should also uncheck the "Build pull requests" option, otherwise any pull
284
+ request targeting `gh-pages` will trigger the reindexing.
285
+
286
+ ![Travis Configuration][11]
287
+
288
+ ### Done
289
+
290
+ Commit all the changes to the files, and then push to `gh-pages`. Travis will
291
+ catch the event and trigger your indexing for you. You can follow the Travis job
292
+ execution directly on [their website][12].
293
+
294
+ ## FAQS
295
+
296
+ ### How can I exclude some HTML nodes from the indexing
297
+
298
+ By default, the plugin will index every HTML node that matches the
299
+ `record_css_selector` CSS selector option. The default value is `p`, meaning
300
+ that it will index all the paragraphs.
301
+
302
+ You can use a [negation
303
+ selector](https://developer.mozilla.org/en/docs/Web/CSS/:not) to be even more
304
+ explicit. For example the value `p:not(.do-not-index)` will index all `<p>`
305
+ paragraphs, *except* those that have the class `do-not-index`.
306
+
307
+ If you need a finer granularity on your indexing that cannot be expressed
308
+ through CSS selectors, you'll have to use the [hook mechanism](#hooks). The
309
+ `custom_hook_each` method takes a [Nokogiri](http://www.nokogiri.org/) HTML node
310
+ as a second argument and should let you write more complex filters.
311
+
312
+
313
+ [1]: https://badge.fury.io/rb/algoliasearch-jekyll.svg
314
+ [2]: https://travis-ci.org/algolia/algoliasearch-jekyll.svg?branch=master
315
+ [3]: https://coveralls.io/repos/algolia/algoliasearch-jekyll/badge.svg?branch=master&service=github
316
+ [4]: https://codeclimate.com/github/algolia/algoliasearch-jekyll/badges/gpa.svg
317
+ [5]: https://www.algolia.com/doc/ruby#indexing-parameters
318
+ [6]: http://bundler.io/
319
+ [7]: https://www.algolia.com/doc/javascript
320
+ [8]: https://github.com/algolia/hyde
321
+ [9]: https://travis-ci.org/
322
+ [10]: http://docs.travis-ci.com/user/environment-variables/
323
+ [11]: /docs/travis-settings.png
324
+ [12]: https://travis-ci.org
data/Rakefile CHANGED
@@ -1,10 +1,12 @@
1
+ # encoding: utf-8
2
+
1
3
  require 'rubygems'
2
4
  require 'bundler'
3
5
  begin
4
6
  Bundler.setup(:default, :development)
5
7
  rescue Bundler::BundlerError => e
6
- warn e.message
7
- warn 'Run `bundle install` to install missing gems'
8
+ $stderr.puts e.message
9
+ $stderr.puts 'Run `bundle install` to install missing gems'
8
10
  exit e.status_code
9
11
  end
10
12
  require 'rake'
@@ -18,18 +20,11 @@ Jeweler::Tasks.new do |gem|
18
20
  gem.version = AlgoliaSearchJekyllVersion.to_s
19
21
  gem.homepage = 'https://github.com/algolia/algoliasearch-jekyll'
20
22
  gem.license = 'MIT'
21
- gem.summary = '[⚠ DEPRECATED ⚠]: Use jekyll-algolia instead'.freeze
22
- gem.description = '[⚠ DEPRECATED ⚠]: Use jekyll-algolia instead'.freeze
23
+ gem.summary = 'AlgoliaSearch for Jekyll'
24
+ gem.description = 'Index all your pages and posts to an Algolia index with ' \
25
+ '`jekyll algolia push`'
23
26
  gem.email = 'tim@pixelastic.com'
24
27
  gem.authors = ['Tim Carry']
25
- gem.post_install_message = <<-MESSAGE
26
- ! The 'algolisearch-jekyll' gem has been deprecated and has been replaced with 'jekyll-algolia'.
27
- ! See: https://rubygems.org/gems/jekyll-algolia
28
- ! And: https://github.com/algolia/jekyll-algolia
29
- !
30
- ! You can get quickly started on the new plugin using this documentation:
31
- ! https://community.algolia.com/jekyll-algolia/getting-started.html
32
- MESSAGE
33
28
 
34
29
  # dependencies defined in Gemfile
35
30
  end
@@ -2,18 +2,18 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: algoliasearch-jekyll 0.9.1 ruby lib
5
+ # stub: algoliasearch-jekyll 0.7.0 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
- s.name = "algoliasearch-jekyll".freeze
9
- s.version = "0.9.1"
8
+ s.name = "algoliasearch-jekyll"
9
+ s.version = "0.7.0"
10
10
 
11
- s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
12
- s.require_paths = ["lib".freeze]
13
- s.authors = ["Tim Carry".freeze]
14
- s.date = "2017-12-21"
15
- s.description = "[\u26A0 DEPRECATED \u26A0]: Use jekyll-algolia instead".freeze
16
- s.email = "tim@pixelastic.com".freeze
11
+ s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
12
+ s.require_paths = ["lib"]
13
+ s.authors = ["Tim Carry"]
14
+ s.date = "2016-06-20"
15
+ s.description = "Index all your pages and posts to an Algolia index with `jekyll algolia push`"
16
+ s.email = "tim@pixelastic.com"
17
17
  s.extra_rdoc_files = [
18
18
  "LICENSE.txt",
19
19
  "README.md"
@@ -40,6 +40,7 @@ Gem::Specification.new do |s|
40
40
  "lib/error_handler.rb",
41
41
  "lib/push.rb",
42
42
  "lib/record_extractor.rb",
43
+ "lib/utils.rb",
43
44
  "lib/version.rb",
44
45
  "scripts/bump_version",
45
46
  "scripts/check_flay",
@@ -58,6 +59,7 @@ Gem::Specification.new do |s|
58
59
  "scripts/watch_v3",
59
60
  "spec/credential_checker_spec.rb",
60
61
  "spec/error_handler_spec.rb",
62
+ "spec/extractor_spec.old",
61
63
  "spec/fixtures/jekyll_version_2/_config.yml",
62
64
  "spec/fixtures/jekyll_version_2/_layouts/default.html",
63
65
  "spec/fixtures/jekyll_version_2/_my-collection/collection-item.html",
@@ -69,8 +71,11 @@ Gem::Specification.new do |s|
69
71
  "spec/fixtures/jekyll_version_2/assets/ring.png",
70
72
  "spec/fixtures/jekyll_version_2/authors.html",
71
73
  "spec/fixtures/jekyll_version_2/excluded.html",
74
+ "spec/fixtures/jekyll_version_2/front_matter.md",
72
75
  "spec/fixtures/jekyll_version_2/hierarchy.md",
73
76
  "spec/fixtures/jekyll_version_2/index.html",
77
+ "spec/fixtures/jekyll_version_2/only-divs.md",
78
+ "spec/fixtures/jekyll_version_2/only-paragraphs.md",
74
79
  "spec/fixtures/jekyll_version_2/page2/index.html",
75
80
  "spec/fixtures/jekyll_version_2/weight.md",
76
81
  "spec/fixtures/jekyll_version_3/_config.yml",
@@ -84,8 +89,11 @@ Gem::Specification.new do |s|
84
89
  "spec/fixtures/jekyll_version_3/assets/ring.png",
85
90
  "spec/fixtures/jekyll_version_3/authors.html",
86
91
  "spec/fixtures/jekyll_version_3/excluded.html",
92
+ "spec/fixtures/jekyll_version_3/front_matter.md",
87
93
  "spec/fixtures/jekyll_version_3/hierarchy.md",
88
94
  "spec/fixtures/jekyll_version_3/index.html",
95
+ "spec/fixtures/jekyll_version_3/only-divs.md",
96
+ "spec/fixtures/jekyll_version_3/only-paragraphs.md",
89
97
  "spec/fixtures/jekyll_version_3/page2/index.html",
90
98
  "spec/fixtures/jekyll_version_3/weight.md",
91
99
  "spec/push_spec.rb",
@@ -98,67 +106,63 @@ Gem::Specification.new do |s|
98
106
  "txt/index_name_missing",
99
107
  "txt/sample"
100
108
  ]
101
- s.homepage = "https://github.com/algolia/algoliasearch-jekyll".freeze
102
- s.licenses = ["MIT".freeze]
103
- s.post_install_message = " ! The 'algolisearch-jekyll' gem has been deprecated and has been replaced with 'jekyll-algolia'.\n ! See: https://rubygems.org/gems/jekyll-algolia\n ! And: https://github.com/algolia/jekyll-algolia\n !\n ! You can get quickly started on the new plugin using this documentation:\n ! https://community.algolia.com/jekyll-algolia/getting-started.html\n".freeze
104
- s.rubygems_version = "2.6.13".freeze
105
- s.summary = "[\u26A0 DEPRECATED \u26A0]: Use jekyll-algolia instead".freeze
109
+ s.homepage = "https://github.com/algolia/algoliasearch-jekyll"
110
+ s.licenses = ["MIT"]
111
+ s.rubygems_version = "2.4.8"
112
+ s.summary = "AlgoliaSearch for Jekyll"
106
113
 
107
114
  if s.respond_to? :specification_version then
108
115
  s.specification_version = 4
109
116
 
110
117
  if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
111
- s.add_runtime_dependency(%q<algoliasearch>.freeze, ["~> 1.12"])
112
- s.add_runtime_dependency(%q<appraisal>.freeze, ["~> 2.1.0"])
113
- s.add_runtime_dependency(%q<awesome_print>.freeze, ["~> 1.6"])
114
- s.add_runtime_dependency(%q<json>.freeze, [">= 1.8.6"])
115
- s.add_runtime_dependency(%q<nokogiri>.freeze, [">= 1.7.2", "~> 1.7"])
116
- s.add_runtime_dependency(%q<verbal_expressions>.freeze, ["~> 0.1.5"])
117
- s.add_development_dependency(%q<rake>.freeze, ["< 11.0"])
118
- s.add_development_dependency(%q<coveralls>.freeze, ["~> 0.8"])
119
- s.add_development_dependency(%q<flay>.freeze, ["~> 2.6"])
120
- s.add_development_dependency(%q<flog>.freeze, ["~> 4.3"])
121
- s.add_development_dependency(%q<guard-rspec>.freeze, ["~> 4.6"])
122
- s.add_development_dependency(%q<jeweler>.freeze, ["~> 2.0"])
123
- s.add_development_dependency(%q<rspec>.freeze, ["~> 3.0"])
124
- s.add_development_dependency(%q<rubocop>.freeze, ["~> 0.31"])
125
- s.add_development_dependency(%q<simplecov>.freeze, ["~> 0.10"])
126
- s.add_development_dependency(%q<rack>.freeze, ["< 2"])
118
+ s.add_runtime_dependency(%q<algoliasearch>, ["~> 1.4"])
119
+ s.add_runtime_dependency(%q<appraisal>, ["~> 2.1.0"])
120
+ s.add_runtime_dependency(%q<awesome_print>, ["~> 1.6"])
121
+ s.add_runtime_dependency(%q<json>, ["~> 1.8"])
122
+ s.add_runtime_dependency(%q<nokogiri>, ["~> 1.6"])
123
+ s.add_runtime_dependency(%q<html-hierarchy-extractor>, [">= 0"])
124
+ s.add_runtime_dependency(%q<verbal_expressions>, ["~> 0.1.5"])
125
+ s.add_development_dependency(%q<coveralls>, ["~> 0.8"])
126
+ s.add_development_dependency(%q<flay>, ["~> 2.6"])
127
+ s.add_development_dependency(%q<flog>, ["~> 4.3"])
128
+ s.add_development_dependency(%q<guard-rspec>, ["~> 4.6"])
129
+ s.add_development_dependency(%q<jeweler>, ["~> 2.0"])
130
+ s.add_development_dependency(%q<rspec>, ["~> 3.0"])
131
+ s.add_development_dependency(%q<rubocop>, ["~> 0.31"])
132
+ s.add_development_dependency(%q<simplecov>, ["~> 0.10"])
127
133
  else
128
- s.add_dependency(%q<algoliasearch>.freeze, ["~> 1.12"])
129
- s.add_dependency(%q<appraisal>.freeze, ["~> 2.1.0"])
130
- s.add_dependency(%q<awesome_print>.freeze, ["~> 1.6"])
131
- s.add_dependency(%q<json>.freeze, [">= 1.8.6"])
132
- s.add_dependency(%q<nokogiri>.freeze, [">= 1.7.2", "~> 1.7"])
133
- s.add_dependency(%q<verbal_expressions>.freeze, ["~> 0.1.5"])
134
- s.add_dependency(%q<rake>.freeze, ["< 11.0"])
135
- s.add_dependency(%q<coveralls>.freeze, ["~> 0.8"])
136
- s.add_dependency(%q<flay>.freeze, ["~> 2.6"])
137
- s.add_dependency(%q<flog>.freeze, ["~> 4.3"])
138
- s.add_dependency(%q<guard-rspec>.freeze, ["~> 4.6"])
139
- s.add_dependency(%q<jeweler>.freeze, ["~> 2.0"])
140
- s.add_dependency(%q<rspec>.freeze, ["~> 3.0"])
141
- s.add_dependency(%q<rubocop>.freeze, ["~> 0.31"])
142
- s.add_dependency(%q<simplecov>.freeze, ["~> 0.10"])
143
- s.add_dependency(%q<rack>.freeze, ["< 2"])
134
+ s.add_dependency(%q<algoliasearch>, ["~> 1.4"])
135
+ s.add_dependency(%q<appraisal>, ["~> 2.1.0"])
136
+ s.add_dependency(%q<awesome_print>, ["~> 1.6"])
137
+ s.add_dependency(%q<json>, ["~> 1.8"])
138
+ s.add_dependency(%q<nokogiri>, ["~> 1.6"])
139
+ s.add_dependency(%q<html-hierarchy-extractor>, [">= 0"])
140
+ s.add_dependency(%q<verbal_expressions>, ["~> 0.1.5"])
141
+ s.add_dependency(%q<coveralls>, ["~> 0.8"])
142
+ s.add_dependency(%q<flay>, ["~> 2.6"])
143
+ s.add_dependency(%q<flog>, ["~> 4.3"])
144
+ s.add_dependency(%q<guard-rspec>, ["~> 4.6"])
145
+ s.add_dependency(%q<jeweler>, ["~> 2.0"])
146
+ s.add_dependency(%q<rspec>, ["~> 3.0"])
147
+ s.add_dependency(%q<rubocop>, ["~> 0.31"])
148
+ s.add_dependency(%q<simplecov>, ["~> 0.10"])
144
149
  end
145
150
  else
146
- s.add_dependency(%q<algoliasearch>.freeze, ["~> 1.12"])
147
- s.add_dependency(%q<appraisal>.freeze, ["~> 2.1.0"])
148
- s.add_dependency(%q<awesome_print>.freeze, ["~> 1.6"])
149
- s.add_dependency(%q<json>.freeze, [">= 1.8.6"])
150
- s.add_dependency(%q<nokogiri>.freeze, [">= 1.7.2", "~> 1.7"])
151
- s.add_dependency(%q<verbal_expressions>.freeze, ["~> 0.1.5"])
152
- s.add_dependency(%q<rake>.freeze, ["< 11.0"])
153
- s.add_dependency(%q<coveralls>.freeze, ["~> 0.8"])
154
- s.add_dependency(%q<flay>.freeze, ["~> 2.6"])
155
- s.add_dependency(%q<flog>.freeze, ["~> 4.3"])
156
- s.add_dependency(%q<guard-rspec>.freeze, ["~> 4.6"])
157
- s.add_dependency(%q<jeweler>.freeze, ["~> 2.0"])
158
- s.add_dependency(%q<rspec>.freeze, ["~> 3.0"])
159
- s.add_dependency(%q<rubocop>.freeze, ["~> 0.31"])
160
- s.add_dependency(%q<simplecov>.freeze, ["~> 0.10"])
161
- s.add_dependency(%q<rack>.freeze, ["< 2"])
151
+ s.add_dependency(%q<algoliasearch>, ["~> 1.4"])
152
+ s.add_dependency(%q<appraisal>, ["~> 2.1.0"])
153
+ s.add_dependency(%q<awesome_print>, ["~> 1.6"])
154
+ s.add_dependency(%q<json>, ["~> 1.8"])
155
+ s.add_dependency(%q<nokogiri>, ["~> 1.6"])
156
+ s.add_dependency(%q<html-hierarchy-extractor>, [">= 0"])
157
+ s.add_dependency(%q<verbal_expressions>, ["~> 0.1.5"])
158
+ s.add_dependency(%q<coveralls>, ["~> 0.8"])
159
+ s.add_dependency(%q<flay>, ["~> 2.6"])
160
+ s.add_dependency(%q<flog>, ["~> 4.3"])
161
+ s.add_dependency(%q<guard-rspec>, ["~> 4.6"])
162
+ s.add_dependency(%q<jeweler>, ["~> 2.0"])
163
+ s.add_dependency(%q<rspec>, ["~> 3.0"])
164
+ s.add_dependency(%q<rubocop>, ["~> 0.31"])
165
+ s.add_dependency(%q<simplecov>, ["~> 0.10"])
162
166
  end
163
167
  end
164
168