coursegen 0.9.20 → 0.9.21
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/Gemfile.lock +33 -37
- data/lib/coursegen/course/helpers/visual_helpers.rb +12 -3
- data/lib/coursegen/course/lib/nanoc_filters.rb +4 -1
- data/lib/coursegen/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6b56c0b807e916341052ecd96905c1bc871865fee63f7c71815fcf9d7814d27b
|
4
|
+
data.tar.gz: 39f5a5c2f4dbd30a4e0c68c55d02e39dfa53fadaa22a468211fdb44a95216086
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 251bdf602d00a8cc6ad043768148ccf30fdc7a47b27c22050d2f014ce3c9b61736d4fb2ba1c990e485f33b9eb6ee28041ffe59edb971e87996fdb202e575999b
|
7
|
+
data.tar.gz: 17bf9af7c79f545d474b4f7b11e7145ed8ada2547443e387d25e04df860d94e501b275429f4301ef02458c53c0566eb1e1e076f81de2f3b8a407fc530a8dcffd
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
coursegen (0.9.
|
4
|
+
coursegen (0.9.21)
|
5
5
|
activesupport
|
6
6
|
adsf
|
7
7
|
byebug
|
@@ -20,12 +20,11 @@ PATH
|
|
20
20
|
GEM
|
21
21
|
remote: https://rubygems.org/
|
22
22
|
specs:
|
23
|
-
activesupport (
|
23
|
+
activesupport (7.0.1)
|
24
24
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
25
25
|
i18n (>= 1.6, < 2)
|
26
26
|
minitest (>= 5.1)
|
27
27
|
tzinfo (~> 2.0)
|
28
|
-
zeitwerk (~> 2.3)
|
29
28
|
addressable (2.8.0)
|
30
29
|
public_suffix (>= 2.0.2, < 5.0)
|
31
30
|
adsf (1.4.6)
|
@@ -41,17 +40,14 @@ GEM
|
|
41
40
|
colored (1.2)
|
42
41
|
concurrent-ruby (1.1.9)
|
43
42
|
cri (2.15.11)
|
44
|
-
ddmemoize (1.0.0)
|
45
|
-
ddmetrics (~> 1.0)
|
46
|
-
ref (~> 2.0)
|
47
43
|
ddmetrics (1.0.1)
|
48
44
|
ddplugin (1.0.3)
|
49
|
-
diff-lcs (1.
|
50
|
-
em-websocket (0.5.
|
45
|
+
diff-lcs (1.5.0)
|
46
|
+
em-websocket (0.5.3)
|
51
47
|
eventmachine (>= 0.12.9)
|
52
|
-
http_parser.rb (~> 0
|
48
|
+
http_parser.rb (~> 0)
|
53
49
|
eventmachine (1.2.7)
|
54
|
-
ffi (1.15.
|
50
|
+
ffi (1.15.5)
|
55
51
|
formatador (0.3.0)
|
56
52
|
guard (2.18.0)
|
57
53
|
formatador (>= 0.2.4)
|
@@ -68,47 +64,48 @@ GEM
|
|
68
64
|
guard-compat (~> 1.0)
|
69
65
|
hamster (3.0.0)
|
70
66
|
concurrent-ruby (~> 1.0)
|
71
|
-
http_parser.rb (0.
|
67
|
+
http_parser.rb (0.8.0)
|
72
68
|
i18n (1.8.11)
|
73
69
|
concurrent-ruby (~> 1.0)
|
74
70
|
icalendar (2.7.1)
|
75
71
|
ice_cube (~> 0.16)
|
76
|
-
ice_cube (0.16.
|
77
|
-
json (2.
|
72
|
+
ice_cube (0.16.4)
|
73
|
+
json (2.6.1)
|
78
74
|
json_schema (0.21.0)
|
79
75
|
kramdown (2.3.1)
|
80
76
|
rexml
|
81
|
-
listen (3.7.
|
77
|
+
listen (3.7.1)
|
82
78
|
rb-fsevent (~> 0.10, >= 0.10.3)
|
83
79
|
rb-inotify (~> 0.9, >= 0.9.10)
|
84
80
|
lumberjack (1.2.8)
|
81
|
+
memo_wise (1.5.0)
|
85
82
|
method_source (1.0.0)
|
86
|
-
minitest (5.
|
87
|
-
nanoc (4.12.
|
83
|
+
minitest (5.15.0)
|
84
|
+
nanoc (4.12.4)
|
88
85
|
addressable (~> 2.5)
|
89
86
|
colored (~> 1.2)
|
90
87
|
nanoc-checking (~> 1.0)
|
91
|
-
nanoc-cli (= 4.12.
|
92
|
-
nanoc-core (= 4.12.
|
88
|
+
nanoc-cli (= 4.12.4)
|
89
|
+
nanoc-core (= 4.12.4)
|
93
90
|
nanoc-deploying (~> 1.0)
|
94
91
|
parallel (~> 1.12)
|
95
92
|
tty-command (~> 0.8)
|
96
93
|
tty-which (~> 0.4)
|
97
|
-
nanoc-checking (1.0.
|
98
|
-
nanoc-cli (~> 4.
|
99
|
-
nanoc-core (~> 4.
|
100
|
-
nanoc-cli (4.12.
|
94
|
+
nanoc-checking (1.0.2)
|
95
|
+
nanoc-cli (~> 4.12, >= 4.12.4)
|
96
|
+
nanoc-core (~> 4.12, >= 4.12.4)
|
97
|
+
nanoc-cli (4.12.4)
|
101
98
|
cri (~> 2.15)
|
102
99
|
diff-lcs (~> 1.3)
|
103
|
-
nanoc-core (= 4.12.
|
100
|
+
nanoc-core (= 4.12.4)
|
104
101
|
zeitwerk (~> 2.1)
|
105
|
-
nanoc-core (4.12.
|
102
|
+
nanoc-core (4.12.4)
|
106
103
|
concurrent-ruby (~> 1.1)
|
107
|
-
ddmemoize (~> 1.0)
|
108
104
|
ddmetrics (~> 1.0)
|
109
105
|
ddplugin (~> 1.0)
|
110
106
|
hamster (~> 3.0)
|
111
107
|
json_schema (~> 0.19)
|
108
|
+
memo_wise (~> 1.5)
|
112
109
|
slow_enumerator_tools (~> 1.0)
|
113
110
|
tty-platform (~> 0.2)
|
114
111
|
zeitwerk (~> 2.1)
|
@@ -122,12 +119,12 @@ GEM
|
|
122
119
|
nanoc-cli (~> 4.11, >= 4.11.14)
|
123
120
|
nanoc-core (~> 4.11, >= 4.11.14)
|
124
121
|
nenv (0.3.0)
|
125
|
-
nokogiri (1.
|
122
|
+
nokogiri (1.13.1-x86_64-darwin)
|
126
123
|
racc (~> 1.4)
|
127
124
|
notiffany (0.1.3)
|
128
125
|
nenv (~> 0.1)
|
129
126
|
shellany (~> 0.0)
|
130
|
-
parallel (1.
|
127
|
+
parallel (1.21.0)
|
131
128
|
pastel (0.8.0)
|
132
129
|
tty-color (~> 0.5)
|
133
130
|
pry (0.14.1)
|
@@ -142,7 +139,6 @@ GEM
|
|
142
139
|
rb-fsevent (0.11.0)
|
143
140
|
rb-inotify (0.10.1)
|
144
141
|
ffi (~> 1.0)
|
145
|
-
ref (2.0.0)
|
146
142
|
rexml (3.2.5)
|
147
143
|
rspec (3.10.0)
|
148
144
|
rspec-core (~> 3.10.0)
|
@@ -150,20 +146,20 @@ GEM
|
|
150
146
|
rspec-mocks (~> 3.10.0)
|
151
147
|
rspec-core (3.10.1)
|
152
148
|
rspec-support (~> 3.10.0)
|
153
|
-
rspec-expectations (3.10.
|
149
|
+
rspec-expectations (3.10.2)
|
154
150
|
diff-lcs (>= 1.2.0, < 2.0)
|
155
151
|
rspec-support (~> 3.10.0)
|
156
152
|
rspec-mocks (3.10.2)
|
157
153
|
diff-lcs (>= 1.2.0, < 2.0)
|
158
154
|
rspec-support (~> 3.10.0)
|
159
|
-
rspec-support (3.10.
|
160
|
-
rubytree (1.0.
|
161
|
-
json (~> 2.1)
|
162
|
-
structured_warnings (~> 0.
|
155
|
+
rspec-support (3.10.3)
|
156
|
+
rubytree (1.0.2)
|
157
|
+
json (~> 2.6.1)
|
158
|
+
structured_warnings (~> 0.4.0)
|
163
159
|
shellany (0.0.1)
|
164
160
|
slow_enumerator_tools (1.1.0)
|
165
161
|
structured_warnings (0.4.0)
|
166
|
-
thor (1.1
|
162
|
+
thor (1.2.1)
|
167
163
|
tty-color (0.6.0)
|
168
164
|
tty-command (0.10.1)
|
169
165
|
pastel (~> 0.8)
|
@@ -171,10 +167,10 @@ GEM
|
|
171
167
|
tty-which (0.5.0)
|
172
168
|
tzinfo (2.0.4)
|
173
169
|
concurrent-ruby (~> 1.0)
|
174
|
-
zeitwerk (2.5.
|
170
|
+
zeitwerk (2.5.3)
|
175
171
|
|
176
172
|
PLATFORMS
|
177
|
-
|
173
|
+
x86_64-darwin-21
|
178
174
|
|
179
175
|
DEPENDENCIES
|
180
176
|
bundler
|
@@ -183,4 +179,4 @@ DEPENDENCIES
|
|
183
179
|
rspec
|
184
180
|
|
185
181
|
BUNDLED WITH
|
186
|
-
2.
|
182
|
+
2.3.3
|
@@ -1,11 +1,20 @@
|
|
1
1
|
module VisualHelpers
|
2
|
-
|
3
|
-
def end_of_lecture(type=:thatsall)
|
2
|
+
def end_of_lecture(type=:random)
|
4
3
|
if (type == :thatsall)
|
5
4
|
part1 = "<slide_break></slide_break>\n\n"
|
6
5
|
part2 = "## See you next time!!\n\n"
|
7
6
|
part3 = "<img src=\"/content/topics/images/thatsallfolks.jpg\" class=\"img-thumbnail d-block mx-auto\" style=\"height:300px;\"/>"
|
8
|
-
|
7
|
+
part4 = ""
|
8
|
+
elsif type == :random
|
9
|
+
part1 = "<slide_break></slide_break>\n\n"
|
10
|
+
part2 = "<h2 class=\"shadow p-3 bg-white rounded\">Thank you. Questions?"
|
11
|
+
part3 = random_image :normal, "800", "100"
|
12
|
+
part4 = "<small> (random Image from picsum.photos)</small>\</h2>"
|
9
13
|
end
|
14
|
+
part1 + part2 + part3 + part4
|
10
15
|
end
|
11
16
|
end
|
17
|
+
|
18
|
+
def random_image(_style, width, height)
|
19
|
+
"<img class=\"img-fluid\ w-100\" src=\"https://picsum.photos/#{width}/#{height}.jpg\" /> "
|
20
|
+
end
|
@@ -17,6 +17,8 @@ Nanoc::Filter.define(:handle_shortcodes) do |content, _params = {}|
|
|
17
17
|
.gsub(Regexp.new(prefix.source + /li (.+)$/.source)) { "<li>#{$1}</li>" }
|
18
18
|
.gsub(Regexp.new(prefix.source + /partbadge/.source), partbadge)
|
19
19
|
.gsub(Regexp.new(prefix.source + /pdfbadge/.source), pdfbadge)
|
20
|
+
.gsub(Regexp.new(prefix.source + /image_random "(\w+)", "(\w+)"/.source)) { "<img src=\"https://picsum.photos/#{$1}/#{$2}.jpg\" /> "}
|
21
|
+
.gsub(Regexp.new(prefix.source + /image_rnd :(\w+), "(.+)", "(.+)"/.source)) { random_image($1, $2, $3) }
|
20
22
|
.gsub(Regexp.new(prefix.source + /section_link :(\w+), :(\w+)/.source)) { link_to_section($1, $2) }
|
21
23
|
.gsub(Regexp.new(prefix.source + /section_include :(\w+), :(\w+)/.source)) { include_from_section($1, $2) }
|
22
24
|
.gsub(Regexp.new(prefix.source + /slide_bigtitle (.+)$/.source), "<slide_break></slide_break>\n\n## \\1")
|
@@ -34,4 +36,5 @@ Nanoc::Filter.define(:handle_shortcodes) do |content, _params = {}|
|
|
34
36
|
.gsub(Regexp.new(prefix.source + /ul_end$/.source)) { "</ul>" }
|
35
37
|
.gsub(Regexp.new(prefix.source + /youtube \"(.+)\"$/.source)) { %Q!<iframe width="560" height="315" src="#{$1}"></iframe>! }
|
36
38
|
.gsub(Regexp.new(prefix.source + /zipbadge/.source), zipbadge)
|
37
|
-
|
39
|
+
|
40
|
+
end
|
data/lib/coursegen/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: coursegen
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.21
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pito Salas
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-02-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -366,7 +366,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
366
366
|
- !ruby/object:Gem::Version
|
367
367
|
version: '0'
|
368
368
|
requirements: []
|
369
|
-
rubygems_version: 3.
|
369
|
+
rubygems_version: 3.3.3
|
370
370
|
signing_key:
|
371
371
|
specification_version: 4
|
372
372
|
summary: Use Nanoc to build courses and deploy them to S3
|