runeblog 0.2.75 → 0.2.76

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 30280ea49b4f2f3da058889fb7cabd535ee55a8a5321a12bd5fc105d5ed74302
4
- data.tar.gz: e0310e08c54c0f0cae977596221b710dfb700f5416547cebe0f57a1375e95482
3
+ metadata.gz: b0c80c77d6bdb17bf32c8a90ed26aa3e98b43493c7b38f7341a359e53bda7cff
4
+ data.tar.gz: 89d0a30d6f2ac56b932c8fd65d966ddcebed9320627ec032ae2d2ac68971a2e6
5
5
  SHA512:
6
- metadata.gz: 83b9df4e7179689012a1eb1b24d2cb26a2295735099331badd450ea08d6ca2b2944cb5f2af0b4ccdf79d7d2bff75665852bc08997c7795c92c63762351242248
7
- data.tar.gz: cd4d4717ab5bfe99532d7f3be3f1aa512725c4fbd6cfa1a24f1639a631c0d196237be04b15f7d72b1376feb214623fb22f9b13a97844de23918554f3833c267a
6
+ metadata.gz: 6bc7626f7e00f7e656982c3bb6f5fea92da173ae430a1b4cdb888dfb170a6af84c33dcd99b6541f57e67c716e23ed484e947ba616f43156dacc7242a97871af2
7
+ data.tar.gz: dd235b09c2f2f592f5a16afa574c62949731cbd634945b79e6969cfdfedbd9eb1132dad5bbd976416354972b4b9bf9d585e75bcd7aec264ec1d40c8f57e92a34
@@ -1,4 +1,5 @@
1
1
  <!-- Miscellaneous local JS pieces are defined here -->
2
+ .nopara
2
3
 
3
4
  <script>
4
5
  function open_main(url) {
@@ -21,13 +21,13 @@ module RuneBlog::Helpers
21
21
 
22
22
  def get_repo_config
23
23
  log!(enter: __method__, level: 3)
24
- @editor = File.read("#@root/data/EDITOR").chomp
25
- @current_view = File.read("#@root/data/VIEW").chomp
26
- @root = File.read("#@root/data/ROOT").chomp
24
+ @editor = File.read(".blogs/data/EDITOR").chomp
25
+ @current_view = File.read(".blogs/data/VIEW").chomp
26
+ @root = File.read(".blogs/data/ROOT").chomp
27
27
  rescue => err
28
- STDERR.puts "Can't read config: #{err}"
29
- STDERR.puts err.backtrace.join("\n")
30
- STDERR.puts "dir = #{Dir.pwd}"
28
+ puts "Can't read config: #{err}"
29
+ puts err.backtrace.join("\n")
30
+ puts "dir = #{Dir.pwd}"
31
31
  end
32
32
 
33
33
  def copy_data(tag, dest)
@@ -84,7 +84,7 @@ module RuneBlog::Helpers
84
84
  dirs.map {|name| RuneBlog::View.new(name) }
85
85
  end
86
86
 
87
- def write_repo_config(root: "#{Dir.pwd}/.blogs", view: "[no view]", editor: "/usr/local/bin/vim")
87
+ def write_repo_config(root: "#{Dir.pwd}/.blogs", view: "#{root}/data/VIEW", editor: "#{root}/data/EDITOR")
88
88
  File.write(root + "/data/ROOT", root + "\n")
89
89
  File.write(root + "/data/VIEW", view.to_s + "\n")
90
90
  File.write(root + "/data/EDITOR", editor + "\n")
@@ -108,6 +108,7 @@ module RuneBlog::Helpers
108
108
 
109
109
  def subdirs(dir)
110
110
  log!(enter: __method__, args: [dir], level: 3)
111
+ STDERR.puts dir
111
112
  dirs = Dir.entries(dir) - %w[. ..]
112
113
  dirs.reject! {|x| ! File.directory?("#@root/views/#{x}") }
113
114
  dirs
@@ -5,7 +5,7 @@ require 'find'
5
5
 
6
6
  require 'runeblog'
7
7
  require 'pathmagic'
8
- # require 'xlate'
8
+ require 'xlate'
9
9
 
10
10
 
11
11
  def init_liveblog # FIXME - a lot of this logic sucks
@@ -636,7 +636,7 @@ def sidebar
636
636
  File.open(wtag/"vars.lt3", "w") do |f|
637
637
  f.puts ".set ad.image = #{img}"
638
638
  end
639
- preprocess cwd: wtag, src: tag, dst: tcard, force: true # , deps: depend # , debug: true
639
+ xlate cwd: wtag, src: tag, dst: tcard, force: true # , deps: depend # , debug: true
640
640
  end
641
641
 
642
642
  _include_file wtag/tcard
@@ -776,7 +776,7 @@ def _make_navbar(orient = :horiz)
776
776
  output.puts %[<li class="nav-item active"> <a class="nav-link" href="index.html">#{cdata}<span class="sr-only">(current)</span></a> </li>]
777
777
  else
778
778
  dir = @blog.root/:views/@blog.view/"themes/standard/banner"
779
- preprocess cwd: dir, src: basename, dst: vdir/"remote/banner"/basename+".html" # , debug: true
779
+ xlate cwd: dir, src: basename, dst: vdir/"remote/banner"/basename+".html" # , debug: true
780
780
  output.puts %[<li class="nav-item"> <a class="nav-link" #{href_main}>#{cdata}</a> </li>]
781
781
  end
782
782
  end
@@ -147,7 +147,7 @@ class RuneBlog
147
147
  dir = @root/:posts/nslug
148
148
  create_dirs(dir)
149
149
  # FIXME dependencies?
150
- preprocess cwd: dir, src: @root/:drafts/sourcefile # , debug: true
150
+ xlate cwd: dir, src: @root/:drafts/sourcefile # , debug: true
151
151
  _deploy_local(dir)
152
152
  rescue => err
153
153
  _tmp_error(err)
@@ -319,7 +319,7 @@ class RuneBlog
319
319
  @theme = @view.dir/"themes/standard"
320
320
  post_entry_name = @theme/"blog/post_entry.lt3"
321
321
  depend = [post_entry_name]
322
- preprocess src: post_entry_name, dst: "/tmp/post_entry.html" # , deps: depend # , debug: true
322
+ xlate src: post_entry_name, dst: "/tmp/post_entry.html" # , deps: depend # , debug: true
323
323
  @_post_entry ||= File.read("/tmp/post_entry.html")
324
324
  vp = post_lookup(id)
325
325
  nslug, aslug, title, date, teaser_text =
@@ -435,9 +435,9 @@ class RuneBlog
435
435
  @theme/"blog/head.lt3",
436
436
  # @theme/"navbar/navbar.lt3",
437
437
  @theme/"blog/index.lt3"] # FIXME what about assets?
438
- preprocess cwd: vdir/"themes/standard/etc", deps: depend,
438
+ xlate cwd: vdir/"themes/standard/etc", deps: depend,
439
439
  src: "blog.css.lt3", copy: vdir/"remote/etc/" # , debug: true
440
- preprocess cwd: vdir/"themes/standard", deps: depend, force: true,
440
+ xlate cwd: vdir/"themes/standard", deps: depend, force: true,
441
441
  src: "blog/generate.lt3", dst: vdir/:remote/"index.html"
442
442
  copy("#{vdir}/assets/*", "#{vdir}/remote/assets/")
443
443
  copy_widget_html(view)
@@ -546,7 +546,7 @@ class RuneBlog
546
546
  # Step 1...
547
547
  create_dirs(pdraft)
548
548
  # FIXME dependencies?
549
- preprocess cwd: pdraft, src: draft, dst: "guts.html" # , debug: true
549
+ xlate cwd: pdraft, src: draft, dst: "guts.html" # , debug: true
550
550
  _post_metadata(draft, pdraft)
551
551
  # Step 2...
552
552
  vposts = @root/:views/view_name/:posts
@@ -556,10 +556,10 @@ class RuneBlog
556
556
  copy(pdraft/"vars.lt3", @theme/:post)
557
557
  # Step 4...
558
558
  # FIXME dependencies?
559
- preprocess cwd: @theme/:post, src: "generate.lt3", force: true,
559
+ xlate cwd: @theme/:post, src: "generate.lt3", force: true,
560
560
  dst: remote/ahtml, copy: @theme/:post # , debug: true
561
561
  # FIXME dependencies?
562
- preprocess cwd: @theme/:post, src: "permalink.lt3",
562
+ xlate cwd: @theme/:post, src: "permalink.lt3",
563
563
  dst: remote/:permalink/ahtml # , debug: true
564
564
  copy_widget_html(view_name)
565
565
  rescue => err
@@ -2,7 +2,7 @@
2
2
  if ! (Object.constants.include?(:RuneBlog) && RuneBlog.constants.include?(:Path))
3
3
 
4
4
  class RuneBlog
5
- VERSION = "0.2.75"
5
+ VERSION = "0.2.76"
6
6
 
7
7
  path = Gem.find_files("runeblog").grep(/runeblog-/).first
8
8
  Path = File.dirname(path)
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.2.75
4
+ version: 0.2.76
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hal Fulton