jekyll-archives-dir-category 0.1.3 → 0.1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/jekyll-archives-dir-category/version.rb +1 -1
- data/lib/jekyll-archives-dir-category.rb +14 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 22182bbaf2a23752a2e113d5a60c8b388bf05aeb59cad9e25b1c2e91874e254c
|
4
|
+
data.tar.gz: 2dbc9ff132961d84eddd40a4e1b74f26f02b1b5cd44da5b1a21407d3f1d417e6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 864249ec41e6658000ddb2fc3b34855f5ec56f366d92a58626f0e87742a91511360049dc3033ad292b7b9c3a6fe2e66364b81780807388623f88d1e56b9fce34
|
7
|
+
data.tar.gz: 28c8dac76d45bf85170fbc12500a02840cecd6580a92468e4e1039c47d1edaf52761ebedfd6cd0afdc7f2342f4488239047b2f6350b945a1248f329973c728a1
|
@@ -224,15 +224,29 @@ module Jekyll
|
|
224
224
|
end
|
225
225
|
|
226
226
|
def read_dates
|
227
|
+
dates_info_years = []
|
227
228
|
years.each do |year, y_posts|
|
228
229
|
append_enabled_date_type({ :year => year }, "year", y_posts)
|
230
|
+
dates_info_months = []
|
229
231
|
months(y_posts).each do |month, m_posts|
|
230
232
|
append_enabled_date_type({ :year => year, :month => month }, "month", m_posts)
|
233
|
+
dates_info_days = []
|
231
234
|
days(m_posts).each do |day, d_posts|
|
232
235
|
append_enabled_date_type({ :year => year, :month => month, :day => day }, "day", d_posts)
|
236
|
+
dates_info_days << "%02d" % day.to_i
|
233
237
|
end
|
238
|
+
dates_info_months << {
|
239
|
+
"month" => "%02d" % month.to_i,
|
240
|
+
"days" => dates_info_days.sort{|a, b| b <=> a},
|
241
|
+
}
|
234
242
|
end
|
243
|
+
dates_info_years << {
|
244
|
+
"year" => "%04d" % year.to_i,
|
245
|
+
"months" => dates_info_months.sort{|a, b| b["month"] <=> a["month"]}
|
246
|
+
}
|
235
247
|
end
|
248
|
+
|
249
|
+
@site.data["years"] = dates_info_years.sort{|a, b| b["year"] <=> a["year"]}
|
236
250
|
end
|
237
251
|
|
238
252
|
# Checks if archive type is enabled in config
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-archives-dir-category
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alfred Xing
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-10-
|
11
|
+
date: 2021-10-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jekyll
|