jekyll-paginate-v2 1.5.1 → 1.5.2

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: 9254e3f2a00c883968a4d9c511541c99a768e9c4
4
- data.tar.gz: b65e829454c441a37f427a29642c6a4ee1f17a0c
3
+ metadata.gz: bf3d484abb23816a1d7b0ddff858bfe8bd9910b0
4
+ data.tar.gz: 38b5e268d53c4e8e5b3a02d5c46ed68178758f41
5
5
  SHA512:
6
- metadata.gz: b886d5e8cada5d00c0fb94617bcb12c46ac6237e155eef36763f7dfdb489b4efd4356429f476764a7555169d7a3fd0e44b14d7132df1a345cfb5aad9fcab12b5
7
- data.tar.gz: 2073fa3f77170a1a76ec41bb7ed0f64016143ca5a00b30d3b93b06b491922045a41288f0014d2fb9b06e1b0d17c493c48130db8dc5720603d3a9be79e83187fb
6
+ metadata.gz: 0c954800a9aec9157258a7bc2b9f19055d8066c9db7d043b670e1a51dfc9e32f8558bfcb7e782350775334096c14031efa8618cfa38d0b62ddd6be62c939919d
7
+ data.tar.gz: 8041aa50ed32b79c0ae9ecb8f87a2ad86b30dbf25793bd9af0cbff3155233603bb753e0f4f2aada8c6b8f0db51afe5fb45d3937cff75c94392b514243c639f4f
@@ -165,6 +165,13 @@ module Jekyll
165
165
  end
166
166
  end
167
167
  end
168
+
169
+ def _debug_print_filtering_info(filter_name, before_count, after_count)
170
+ # Debug print the config
171
+ if @debug
172
+ puts "Pagination: ".rjust(20) + " Filtering by: "+filter_name.to_s.ljust(9) + " " + before_count.to_s.rjust(3) + " => " + after_count.to_s
173
+ end
174
+ end
168
175
 
169
176
  #
170
177
  # Rolls through all the pages passed in and finds all pages that have pagination enabled on them.
@@ -196,9 +203,15 @@ module Jekyll
196
203
  using_posts = all_posts
197
204
 
198
205
  # Now start filtering out any posts that the user doesn't want included in the pagination
206
+ before = using_posts.size.to_i
199
207
  using_posts = PaginationIndexer.read_config_value_and_filter_posts(config, 'category', using_posts, all_categories)
208
+ self._debug_print_filtering_info('Category', before, using_posts.size.to_i)
209
+ before = using_posts.size.to_i
200
210
  using_posts = PaginationIndexer.read_config_value_and_filter_posts(config, 'tag', using_posts, all_tags)
211
+ self._debug_print_filtering_info('Tag', before, using_posts.size.to_i)
212
+ before = using_posts.size.to_i
201
213
  using_posts = PaginationIndexer.read_config_value_and_filter_posts(config, 'locale', using_posts, all_locales)
214
+ self._debug_print_filtering_info('Locale', before, using_posts.size.to_i)
202
215
 
203
216
  # Apply sorting to the posts if configured, any field for the post is available for sorting
204
217
  if config['sort_field']
@@ -1,8 +1,8 @@
1
1
  module Jekyll
2
2
  module PaginateV2
3
- VERSION = "1.5.1"
3
+ VERSION = "1.5.2"
4
4
  # When modifying remember to issue a new tag command in git before committing, then push the new tag
5
- # git tag -a v1.5.1 -m "Gem v1.5.1"
5
+ # git tag -a v1.5.2 -m "Gem v1.5.2"
6
6
  # git push origin --tags
7
7
  end # module PaginateV2
8
8
  end # module Jekyll
@@ -8,7 +8,7 @@ module Jekyll::PaginateV2::Generator
8
8
  DEFAULT.must_include 'collection'
9
9
  DEFAULT.must_include 'per_page'
10
10
  DEFAULT.must_include 'permalink'
11
- DEFAULT.must_include 'title_suffix'
11
+ DEFAULT.must_include 'title'
12
12
  DEFAULT.must_include 'page_num'
13
13
  DEFAULT.must_include 'sort_reverse'
14
14
  DEFAULT.must_include 'sort_field'
@@ -22,7 +22,7 @@ module Jekyll::PaginateV2::Generator
22
22
  DEFAULT['collection'].must_equal 'posts'
23
23
  DEFAULT['per_page'].must_equal 10
24
24
  DEFAULT['permalink'].must_equal '/page:num/'
25
- DEFAULT['title_suffix'].must_equal ' - page :num'
25
+ DEFAULT['title'].must_equal ':title - page :num'
26
26
  DEFAULT['page_num'].must_equal 1
27
27
  DEFAULT['sort_reverse'].must_equal false
28
28
  DEFAULT['sort_field'].must_equal 'date'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-paginate-v2
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.1
4
+ version: 1.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sverrir Sigmundarson