runeblog 0.1.90 → 0.1.91
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/helpers-blog.rb +8 -5
- data/lib/liveblog.rb +17 -25
- data/lib/runeblog.rb +18 -29
- data/lib/runeblog_version.rb +1 -1
- data/themes/standard/blog/generate.lt3 +2 -2
- data/themes/standard/blog/index.lt3 +4 -0
- data/themes/standard/liveblog.out +27 -0
- data/themes/standard/{about.html → navbar/about.html} +0 -0
- data/themes/standard/{navbar.lt3 → navbar/navbar.lt3} +0 -0
- data/themes/standard/{post-generate.lt3 → post/generate.lt3} +5 -1
- data/themes/standard/{post-head.lt3 → post/head.lt3} +0 -0
- data/themes/standard/{post-index.lt3 → post/index.lt3} +0 -0
- metadata +8 -9
- data/themes/standard/blog-index.lt3 +0 -6
- data/themes/standard/blog-meta.lt3 +0 -3
- data/themes/standard/blog-navbar.lt3 +0 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d0ecc0207a215d6ecb745fc93ef707d330990f287637f0e6838ea996ef8a3922
|
4
|
+
data.tar.gz: f00e1ab6255ae818b30d345408e44a3735dc907b9d16cf9ab51fc473bd6bedeb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9e13e2828c71f69a5fd40dc4da1c1cf604e2222ad8d1c919e4402a662e7224aa488512f6c2107d48336a96049cf61d830fe93d4247e278c7ac755e511ef7b03b
|
7
|
+
data.tar.gz: 26aac596e6e68e5b37bd36c1aacb193f22da135a5e299a68437f46b34d52e74f343e5e22960b6d879a132d772febb66049876dd5f4a1ba969dccdfd9f942d7f7
|
data/lib/helpers-blog.rb
CHANGED
@@ -133,11 +133,14 @@ end
|
|
133
133
|
files
|
134
134
|
end
|
135
135
|
|
136
|
-
def
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
136
|
+
def create_dirs(*dirs)
|
137
|
+
dirs.each do |dir|
|
138
|
+
dir = dir.to_s # symbols allowed
|
139
|
+
next if Dir.exist?(dir)
|
140
|
+
cmd = "mkdir -p #{dir} >/dev/null"
|
141
|
+
result = system(cmd)
|
142
|
+
raise CantCreateDir(dir) unless result
|
143
|
+
end
|
141
144
|
end
|
142
145
|
|
143
146
|
def interpolate(str, binding)
|
data/lib/liveblog.rb
CHANGED
@@ -8,15 +8,6 @@ require 'runeblog'
|
|
8
8
|
errfile = File.new("liveblog.out", "w")
|
9
9
|
STDERR.reopen(errfile)
|
10
10
|
|
11
|
-
# def title # side-effect
|
12
|
-
# def pubdate # side-effect
|
13
|
-
# def tags # side-effect
|
14
|
-
# def views # side-effect
|
15
|
-
# def pin # side-effect
|
16
|
-
# def write_post # side-effect
|
17
|
-
# def main # side-effect
|
18
|
-
# def _post_lookup(postid) # side-effect
|
19
|
-
|
20
11
|
def init_liveblog # FIXME - a lot of this logic sucks
|
21
12
|
here = Dir.pwd
|
22
13
|
dir = here
|
@@ -122,7 +113,7 @@ def _passthru_noline(line)
|
|
122
113
|
_out "<p>" if line.empty? && ! @_nopara
|
123
114
|
end
|
124
115
|
|
125
|
-
def title
|
116
|
+
def title
|
126
117
|
raise "'post' was not called" unless @meta
|
127
118
|
title = @_data.chomp
|
128
119
|
@meta.title = title
|
@@ -131,7 +122,7 @@ def title # side-effect
|
|
131
122
|
_optional_blank_line
|
132
123
|
end
|
133
124
|
|
134
|
-
def pubdate
|
125
|
+
def pubdate
|
135
126
|
raise "'post' was not called" unless @meta
|
136
127
|
_debug "data = #@_data"
|
137
128
|
# Check for discrepancy?
|
@@ -151,21 +142,21 @@ def image # primitive so far
|
|
151
142
|
_optional_blank_line
|
152
143
|
end
|
153
144
|
|
154
|
-
def tags
|
145
|
+
def tags
|
155
146
|
raise "'post' was not called" unless @meta
|
156
147
|
_debug "args = #{_args}"
|
157
148
|
@meta.tags = _args.dup || []
|
158
149
|
_optional_blank_line
|
159
150
|
end
|
160
151
|
|
161
|
-
def views
|
152
|
+
def views
|
162
153
|
raise "'post' was not called" unless @meta
|
163
154
|
_debug "data = #{_args}"
|
164
|
-
@meta.views = _args.dup
|
155
|
+
@meta.views = _args.dup
|
165
156
|
_optional_blank_line
|
166
157
|
end
|
167
158
|
|
168
|
-
def pin
|
159
|
+
def pin
|
169
160
|
raise "'post' was not called" unless @meta
|
170
161
|
_debug "data = #{_args}"
|
171
162
|
# verify only already-specified views?
|
@@ -196,7 +187,7 @@ def list!
|
|
196
187
|
_optional_blank_line
|
197
188
|
end
|
198
189
|
|
199
|
-
def write_post
|
190
|
+
def write_post
|
200
191
|
raise "'post' was not called" unless @meta
|
201
192
|
save = Dir.pwd
|
202
193
|
@postdir.gsub!(/\/\//, "/") # FIXME unneeded?
|
@@ -231,7 +222,7 @@ def finalize
|
|
231
222
|
return
|
232
223
|
end
|
233
224
|
if @blog.nil?
|
234
|
-
return @meta
|
225
|
+
return @meta
|
235
226
|
end
|
236
227
|
|
237
228
|
@slug = @blog.make_slug(@meta)
|
@@ -361,15 +352,16 @@ def meta
|
|
361
352
|
_out str
|
362
353
|
end
|
363
354
|
|
364
|
-
def
|
355
|
+
def recent_posts # side-effect
|
365
356
|
_out %[<div class="col-lg-9 col-md-9 col-sm-9 col-xs-12">]
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
357
|
+
all_teasers
|
358
|
+
## which = _args[0]
|
359
|
+
## case which
|
360
|
+
## when "recent_posts"
|
361
|
+
## all_teasers
|
362
|
+
## when "post" # No longer needed??
|
363
|
+
## _out %[<iframe style="width: 100vw;height: 100vh;position: relative;" src='whats-at-stubbs.html' width=100% frameborder="0" allowfullscreen></iframe>]
|
364
|
+
## end
|
373
365
|
_out %[</div>]
|
374
366
|
end
|
375
367
|
|
data/lib/runeblog.rb
CHANGED
@@ -54,11 +54,9 @@ class RuneBlog
|
|
54
54
|
$_blog = self # Dumber still?
|
55
55
|
root = Dir.pwd + "/" + root
|
56
56
|
raise BlogRepoAlreadyExists if Dir.exist?(root)
|
57
|
-
|
57
|
+
create_dirs(root)
|
58
58
|
Dir.chdir(root) do
|
59
|
-
|
60
|
-
create_dir("views")
|
61
|
-
#? create_dir("assets")
|
59
|
+
create_dirs(:drafts, :views)
|
62
60
|
new_sequence
|
63
61
|
end
|
64
62
|
put_config(root: root)
|
@@ -172,36 +170,27 @@ class RuneBlog
|
|
172
170
|
|
173
171
|
vdir = "#@root/views/#{arg}/"
|
174
172
|
raise DirAlreadyExists(vdir) if Dir.exist?(vdir)
|
175
|
-
|
173
|
+
create_dirs(vdir)
|
176
174
|
up = Dir.pwd
|
177
175
|
|
178
|
-
Dir.chdir(vdir)
|
179
|
-
|
180
|
-
#
|
181
|
-
|
182
|
-
|
183
|
-
|
176
|
+
Dir.chdir(vdir) do
|
177
|
+
x = RuneBlog::Default
|
178
|
+
copy!("#{Themes}", "themes")
|
179
|
+
create_dirs(:assets, :posts)
|
180
|
+
create_dirs(:staging, :remote)
|
181
|
+
copy!("themes/standard/*", "staging/")
|
182
|
+
copy!("themes/standard/*", "remote/")
|
184
183
|
|
185
|
-
|
186
|
-
|
187
|
-
# create_dir('staging/blog')
|
188
|
-
create_dir('remote')
|
189
|
-
# create_dir('remote/assets')
|
184
|
+
pub = "user: xxx\nserver: xxx\ndocroot: xxx\npath: xxx\nproto: xxx\n"
|
185
|
+
dump(pub, "publish")
|
190
186
|
|
191
|
-
|
192
|
-
# copy!("themes/standard/blog/*", "staging/blog/")
|
193
|
-
copy!("themes/standard/*", "remote/")
|
187
|
+
# Add to global.lt3 here? FIXME
|
194
188
|
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
view = RuneBlog::View.new(arg)
|
201
|
-
self.view = view
|
202
|
-
vdir = self.view.dir
|
203
|
-
dump("Initial creation", "last_published")
|
204
|
-
Dir.chdir(up)
|
189
|
+
view = RuneBlog::View.new(arg)
|
190
|
+
self.view = view
|
191
|
+
vdir = self.view.dir
|
192
|
+
dump("Initial creation", "last_published")
|
193
|
+
end
|
205
194
|
@views << view
|
206
195
|
@views
|
207
196
|
end
|
data/lib/runeblog_version.rb
CHANGED
@@ -7,10 +7,10 @@
|
|
7
7
|
.include global.lt3
|
8
8
|
.include blog/head.lt3
|
9
9
|
<body>
|
10
|
-
$.include navbar.lt3
|
10
|
+
$.include navbar/navbar.lt3
|
11
11
|
<div class="content container-fluid mt-4">
|
12
12
|
<div class="row">
|
13
|
-
$.include blog
|
13
|
+
$.include blog/index.lt3
|
14
14
|
</div>
|
15
15
|
</div>
|
16
16
|
</body>
|
@@ -0,0 +1,27 @@
|
|
1
|
+
In /Users/Hal/Dropbox/files/runeblog/themes/standard
|
2
|
+
- about to process global.lt3
|
3
|
+
...finished
|
4
|
+
In /Users/Hal/Dropbox/files/runeblog/themes/standard
|
5
|
+
- about to process blog/head.lt3
|
6
|
+
In /Users/Hal/Dropbox/files/runeblog/themes/standard
|
7
|
+
- about to process meta.lt3
|
8
|
+
...finished
|
9
|
+
In /Users/Hal/Dropbox/files/runeblog/themes/standard
|
10
|
+
- about to process navbar.lt3
|
11
|
+
...finished
|
12
|
+
In /Users/Hal/Dropbox/files/runeblog/themes/standard
|
13
|
+
- about to process blog-index.lt3
|
14
|
+
In /Users/Hal/Dropbox/files/runeblog/themes/standard
|
15
|
+
- about to process sidebar/ad.lt3
|
16
|
+
...finished
|
17
|
+
In /Users/Hal/Dropbox/files/runeblog/themes/standard
|
18
|
+
- about to process sidebar/news.lt3
|
19
|
+
...finished
|
20
|
+
In /Users/Hal/Dropbox/files/runeblog/themes/standard
|
21
|
+
- about to process sidebar/calendar.lt3
|
22
|
+
...finished
|
23
|
+
In /Users/Hal/Dropbox/files/runeblog/themes/standard
|
24
|
+
- about to process sidebar/tag-cloud.lt3
|
25
|
+
...finished
|
26
|
+
...finished
|
27
|
+
...finished
|
File without changes
|
File without changes
|
@@ -8,9 +8,13 @@
|
|
8
8
|
|
9
9
|
.include global.lt3
|
10
10
|
.include blog/head.lt3
|
11
|
+
. post head stuff...
|
12
|
+
|
13
|
+
. html/body mismatch?
|
14
|
+
|
11
15
|
<section class="post">
|
12
16
|
<div class="entry-content">
|
13
|
-
$.include post
|
17
|
+
$.include post/index.lt3
|
14
18
|
</div>
|
15
19
|
</section>
|
16
20
|
</body>
|
File without changes
|
File without changes
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: runeblog
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.91
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Hal Fulton
|
@@ -78,22 +78,21 @@ files:
|
|
78
78
|
- test/make_blog.rb
|
79
79
|
- test/test
|
80
80
|
- themes/standard/README
|
81
|
-
- themes/standard/about.html
|
82
81
|
- themes/standard/assets/blog.css
|
83
82
|
- themes/standard/assets/favicon.ico
|
84
|
-
- themes/standard/blog-index.lt3
|
85
|
-
- themes/standard/blog-meta.lt3
|
86
|
-
- themes/standard/blog-navbar.lt3
|
87
83
|
- themes/standard/blog/generate.lt3
|
88
84
|
- themes/standard/blog/head.lt3
|
85
|
+
- themes/standard/blog/index.lt3
|
89
86
|
- themes/standard/blog/post_entry.lt3
|
90
87
|
- themes/standard/global.lt3
|
91
88
|
- themes/standard/head.lt3
|
89
|
+
- themes/standard/liveblog.out
|
92
90
|
- themes/standard/meta.lt3
|
93
|
-
- themes/standard/navbar.
|
94
|
-
- themes/standard/
|
95
|
-
- themes/standard/post
|
96
|
-
- themes/standard/post
|
91
|
+
- themes/standard/navbar/about.html
|
92
|
+
- themes/standard/navbar/navbar.lt3
|
93
|
+
- themes/standard/post/generate.lt3
|
94
|
+
- themes/standard/post/head.lt3
|
95
|
+
- themes/standard/post/index.lt3
|
97
96
|
- themes/standard/sidebar/ad.lt3
|
98
97
|
- themes/standard/sidebar/calendar.lt3
|
99
98
|
- themes/standard/sidebar/news.lt3
|