runeblog 0.3.33 → 0.3.34
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/blog +1 -1
- data/lib/menus.rb +1 -1
- data/lib/processing.rb +8 -0
- data/lib/publish.rb +5 -3
- data/lib/repl.rb +4 -4
- data/lib/runeblog.rb +1 -1
- data/lib/runeblog_version.rb +1 -1
- data/lib/view.rb +1 -10
- 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: 5b835a9fea2fa013b708dd9b6f99b411f34517fe6a04f27c130b4fbf3f802881
|
4
|
+
data.tar.gz: 818099d61bdfa21031f7e6c13580536b64cdbd27ab2e69c196fccb4c765bd135
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e87e7985ebb4302986520fe593d16bca67cc03f2be97b821c3a0ca5f5f0eda172df6509b148eacc701f85cc86a3199e24876d40d0648c9ad5f8248034caeaa4d
|
7
|
+
data.tar.gz: 8b764722bae84a9bc73b3aadbae80599b3cd69252f4f83b7e208bde3b6aadb8cd183d0fb806e5985b77fcc0b75f80abe22dbe813615ca08eb5f5de3dcbcd53bd
|
data/bin/blog
CHANGED
data/lib/menus.rb
CHANGED
@@ -105,7 +105,7 @@ Menu.top_config = {
|
|
105
105
|
"Generator for a post" => proc { edit_post_generate },
|
106
106
|
" HEAD info for post" => proc { edit_post_head },
|
107
107
|
" Content for post" => proc { edit_post_index },
|
108
|
-
"Variables (general!)"
|
108
|
+
"Variables (general!)" => proc { edit_view_global },
|
109
109
|
" View-specific" => proc { edit_settings_view },
|
110
110
|
" Recent posts" => proc { edit_settings_recent },
|
111
111
|
" Publishing" => proc { edit_settings_publish },
|
data/lib/processing.rb
CHANGED
@@ -76,9 +76,17 @@ rescue => err
|
|
76
76
|
log!(str: msg)
|
77
77
|
end
|
78
78
|
|
79
|
+
# glv 2 - No such file or directory @ rb_check_realpath_internal - /Users/Hal/.blogs/views/computing/themes/standard/settings/view.txt
|
80
|
+
|
79
81
|
def get_live_vars(src)
|
80
82
|
dir, base = File.dirname(src), File.basename(src)
|
83
|
+
# puts "glv 1: src = #{src.inspect} dir,base = #{dir.inspect}, #{base.inspect}"
|
81
84
|
live = Livetext.customize(call: [".nopara"])
|
85
|
+
puts "glv 2: cd #{dir} xform #{base}\n "
|
86
|
+
# HAL9000:~ Hal$ find .blogs/views/computing/ -name global.lt3
|
87
|
+
# .blogs/views/computing//themes/standard/global.lt3
|
88
|
+
# HAL9000:~ Hal$ find .blogs/views/computing/ -name view.txt
|
89
|
+
# .blogs/views/computing//settings/view.txt
|
82
90
|
Dir.chdir(dir) { live.xform_file(base) }
|
83
91
|
live
|
84
92
|
rescue => e
|
data/lib/publish.rb
CHANGED
@@ -14,13 +14,15 @@ class RuneBlog::Publishing
|
|
14
14
|
def initialize(view)
|
15
15
|
log!(enter: __method__, args: [view.to_s])
|
16
16
|
@blog = RuneBlog.blog
|
17
|
-
|
18
|
-
# CHANGED
|
19
|
-
dir = @blog.root/:views/view/:data
|
17
|
+
dir = @blog.root/:views/view/"themes/standard/"
|
20
18
|
gfile = dir/"global.lt3"
|
19
|
+
there = File.exist?(gfile)
|
20
|
+
puts "Pub#init 0 gfile = $ gfile.inspect} exist = #{there}"
|
21
21
|
return unless File.exist?(gfile) # FIXME Hackish as hell
|
22
22
|
|
23
|
+
# puts "Pub#init 1"
|
23
24
|
live = get_live_vars(gfile)
|
25
|
+
# puts "Pub#init 2 - vars = #{live.vars.inspect}\n "
|
24
26
|
@user = live.vars["publish.user"]
|
25
27
|
@server = live.vars["publish.server"]
|
26
28
|
@docroot = live.vars["publish.docroot"]
|
data/lib/repl.rb
CHANGED
@@ -9,12 +9,12 @@ require 'menus'
|
|
9
9
|
Signal.trap("INT") { puts "Don't :)" }
|
10
10
|
|
11
11
|
module RuneBlog::REPL
|
12
|
+
|
12
13
|
def edit_file(file, vim: "")
|
13
14
|
ed = @blog.editor
|
14
|
-
STDERR.puts ">>> edit_file: ed = #{ed.inspect}"
|
15
15
|
params = vim if ed =~ /vim$/
|
16
|
-
|
17
|
-
|
16
|
+
cmd = "#{@blog.editor} #{file} #{params}"
|
17
|
+
result = system!(cmd)
|
18
18
|
raise EditorProblem(file) unless result
|
19
19
|
cmd_clear
|
20
20
|
end
|
@@ -41,7 +41,7 @@ STDERR.puts ">>> edit_file: after system call"
|
|
41
41
|
|
42
42
|
def cmd_config
|
43
43
|
hash = {"Variables (General)" => "global.lt3",
|
44
|
-
" View-specific" => "
|
44
|
+
" View-specific" => "../../settings/view.txt",
|
45
45
|
" Recent posts" => "../../settings/recent.txt",
|
46
46
|
" Publishing" => "../../settings/publish.txt",
|
47
47
|
"Configuration: enable/disable" => "../../settings/features.txt",
|
data/lib/runeblog.rb
CHANGED
data/lib/runeblog_version.rb
CHANGED
data/lib/view.rb
CHANGED
@@ -12,6 +12,7 @@ class RuneBlog::View
|
|
12
12
|
@blog = RuneBlog.blog
|
13
13
|
@name = name
|
14
14
|
@publisher = RuneBlog::Publishing.new(name)
|
15
|
+
# puts "view #{name}: pub = #{@publisher.inspect}"
|
15
16
|
@can_publish = true # FIXME
|
16
17
|
# @blog.view = self # NOOOO??
|
17
18
|
get_globals
|
@@ -39,19 +40,9 @@ class RuneBlog::View
|
|
39
40
|
return unless File.exist?(gfile) # Hackish!! how is View.new called from create_view??
|
40
41
|
|
41
42
|
live = Livetext.customize(call: ".nopara")
|
42
|
-
puts "get_globals - 1 - transforming #{gfile}"
|
43
|
-
# FIXME - error here somehow:
|
44
|
-
# get_globals - 1 - transforming /private/tmp/.blogs/views/foobar/data/global.lt3
|
45
|
-
# >> variables: pre="view" file="../settings/view.txt" pwd=/private/tmp
|
46
|
-
# No such dir "../settings" (file ../settings/view.txt)
|
47
|
-
# No such dir "../settings" (file ../settings/view.txt)
|
48
|
-
# get_globals - 2
|
49
43
|
live.xform_file(gfile)
|
50
|
-
puts "get_globals - 2"
|
51
44
|
live.setvar("ViewDir", @blog.root/:views/@name)
|
52
|
-
puts "get_globals - 3"
|
53
45
|
live.setvar("View", @name)
|
54
|
-
puts "get_globals - 4"
|
55
46
|
@globals = live.vars
|
56
47
|
# dump_globals_stderr
|
57
48
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: runeblog
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.34
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Hal Fulton
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-05-
|
11
|
+
date: 2024-05-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: livetext
|