zarchitect 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/zarchitect/post.rb +10 -0
- data/lib/zarchitect/rss.rb +1 -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: f9315ed3ab45cedda13e7521ce45c56a39d214187f8cd5813c913ef5bd948942
|
|
4
|
+
data.tar.gz: e7328e7421f7443638e618be2968c9f1b7fb097cedf20c595540cc25866e3e01
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: dc10f2c7c575ea575e6c5ac0c91f621f17c14e797d34ff48d9732dc407bdd1b5640da5c7242cb3a60da86f9fbecbcb31a08da0009100365f4c9d78029e2bfbf4
|
|
7
|
+
data.tar.gz: e6831aa4fd6cc2f60d1e51ee17bf3fead138b46358c3f4cb97696f648449c8b1318cd79dfdfb3cbb8e6b72329b4ae3375b9cdaacd8fae445f61266d647130753
|
data/lib/zarchitect/post.rb
CHANGED
|
@@ -12,6 +12,7 @@ class Post < Zarchitect
|
|
|
12
12
|
@id = @conf.id.clone if @conf.has_option?("id")
|
|
13
13
|
@category = nil
|
|
14
14
|
set_draft
|
|
15
|
+
set_rss
|
|
15
16
|
set_date
|
|
16
17
|
fetch_category if @conf.has_option?("category")
|
|
17
18
|
create_dir
|
|
@@ -44,6 +45,10 @@ class Post < Zarchitect
|
|
|
44
45
|
@html.write
|
|
45
46
|
end
|
|
46
47
|
|
|
48
|
+
def rss?
|
|
49
|
+
return @rss
|
|
50
|
+
end
|
|
51
|
+
|
|
47
52
|
private
|
|
48
53
|
|
|
49
54
|
def fetch_content
|
|
@@ -101,6 +106,11 @@ class Post < Zarchitect
|
|
|
101
106
|
@draft = @conf.draft if @conf.has_option?("draft")
|
|
102
107
|
end
|
|
103
108
|
|
|
109
|
+
def set_rss
|
|
110
|
+
@rss = true
|
|
111
|
+
@rss = @conf.rss if @conf.has_option?("rss")
|
|
112
|
+
end
|
|
113
|
+
|
|
104
114
|
def set_date
|
|
105
115
|
@date = nil
|
|
106
116
|
if @section.conf.collection
|
data/lib/zarchitect/rss.rb
CHANGED
|
@@ -6,6 +6,7 @@ class ZRSS < Zarchitect
|
|
|
6
6
|
|
|
7
7
|
def try_item(page)
|
|
8
8
|
return if page.draft
|
|
9
|
+
return unless page.rss?
|
|
9
10
|
if @items.count < Zarchitect.conf.rss_size # simply add page to rss items
|
|
10
11
|
@items.push RSSItem.new(page)
|
|
11
12
|
else # check if it's more recent than the oldest item in the feed
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: zarchitect
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.0.
|
|
4
|
+
version: 1.0.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- ryu
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2021-12-22 00:00:00.000000000 Z
|
|
12
12
|
dependencies: []
|
|
13
13
|
description: Yet another static website generator
|
|
14
14
|
email: ryu@tohya.net
|