jekyll-order 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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f4e5614901aa22f1588c230ef739912c15b36e7d9798d96e2ae3d24908e32e50
4
- data.tar.gz: ffb9ecdd369c6289495f412cb0ca01cb69d4b3d953fa95022d8bc59ca2361854
3
+ metadata.gz: bde9f922e0887b6aa9ad61aedd71bc16687c934f5d2352285813444254ed1ae0
4
+ data.tar.gz: 1b3dd8f3d1b8304ca0caeb306e02d69a17bdddc8a848e7b18f2f34241d1dab3b
5
5
  SHA512:
6
- metadata.gz: 8afa282aaef45975763ba788c1872b52d3f2b5a01a201cc4bb5b6050247d95a06c727fec4dfdb0699687bcc3b07da77f5f785eb28aedd8cb698d52ae373b92a5
7
- data.tar.gz: a6244b345e9955fc6d228afb164dbdb27e524e052dbf9aa03a116cb9a1857c7f97f5f932ae6e2375ffa8238f264eeb67d3acbb63f3d7c31269930934dfe13534
6
+ metadata.gz: cded0c9376bed939303a1cb330affd9cd33907d79687c8812d5f987e5026f3cf18cdecfb48dd5e29b1c4d1194aa77652d0b82b752aed3617332628f06ccbd3f0
7
+ data.tar.gz: 59d358012be29bd362da13c15a75059b79009c7bd582597fde203bf546925177107d1532aac8d7bfa81eef50e91e9d5e2995b94f4a088c9d9a87eae886417643
data/.gitignore CHANGED
@@ -6,3 +6,5 @@
6
6
  /pkg/
7
7
  /spec/reports/
8
8
  /tmp/
9
+ /published/
10
+ Gemfile.lock
data/Makefile ADDED
@@ -0,0 +1,13 @@
1
+ gem := $(notdir $(PWD))
2
+
3
+ all: build publish
4
+
5
+ build:
6
+ echo $(gem)
7
+ chmod -R o=g .
8
+ gem build $(gem).gemspec
9
+
10
+ publish:
11
+ cloak view rubygems | xargs -rI {} gem push --otp {} *.gem
12
+ mkdir -p published/
13
+ mv *.gem published/
data/lib/jekyll-order.rb CHANGED
@@ -2,3 +2,4 @@
2
2
 
3
3
  require_relative 'jekyll/drops/site_drop'
4
4
  require_relative 'jekyll/archives/archive_decorator'
5
+ require_relative 'jekyll/filters/order'
@@ -0,0 +1,15 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Jekyll
4
+ module Filters
5
+ module Order
6
+ def order(input)
7
+ input.sort_by do |post|
8
+ [post.data.dig('order').to_i, post.data['date']]
9
+ end.reverse
10
+ end
11
+ end
12
+ end
13
+ end
14
+
15
+ Liquid::Template.register_filter(Jekyll::Filters::Order)
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Jekyll
4
4
  module Order
5
- VERSION = '0.1.3'
5
+ VERSION = '0.1.4'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-order
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - f
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-02-22 00:00:00.000000000 Z
11
+ date: 2021-03-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -49,6 +49,7 @@ files:
49
49
  - CODE_OF_CONDUCT.md
50
50
  - Gemfile
51
51
  - LICENSE
52
+ - Makefile
52
53
  - README.md
53
54
  - Rakefile
54
55
  - bin/console
@@ -57,6 +58,7 @@ files:
57
58
  - lib/jekyll-order.rb
58
59
  - lib/jekyll/archives/archive_decorator.rb
59
60
  - lib/jekyll/drops/site_drop.rb
61
+ - lib/jekyll/filters/order.rb
60
62
  - lib/jekyll/order.rb
61
63
  - lib/jekyll/order/version.rb
62
64
  homepage: https://0xacab.org/sutty/jekyll/jekyll-order