runeblog 0.1.26 → 0.1.27

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a7f74526fa315a736ee77fcc1bb3ca62a35dab08dea644e5d734239f2f285e14
4
- data.tar.gz: 02bf784d0020ffd59e707cabc1fb4c1ff57c66d149405f3e83650ecaf836608d
3
+ metadata.gz: 8a62d185febf4123fc8d4ed23590b5de3b55ca151f014839d2d843fe2c29c5e6
4
+ data.tar.gz: ca9dffc3767d974cccb94af5a9dfa5fc29de7b59acec33dbcac081129440b872
5
5
  SHA512:
6
- metadata.gz: 4af84cc5d0c71b67c3d9aaf8ef76924057579193a08e516d3914e07bc1f99f8cc4689c7b4c0649290932d420fc1df84e4e918d8052dcff238ebd663119245a01
7
- data.tar.gz: 72f5a4d0ac5cbaa68cf9e6df062d93485efb45735b501de8f89201880df1d6e1278aab4e4b41ae805e0bd7a73b3d5779a28a6507e885e95de0a9021dfd421385
6
+ metadata.gz: 65f13f6fc0c058c4cd9d4344fa8fc2f91b3856a11795c7b3a67f1d47f449fa7bb9e672826005d8c2d3aa999cdc2aa79eb3e64281fe79f5597e2cf6c760b6d1d2
7
+ data.tar.gz: f4c00317f30a3fc619d7d39d4a198a39ae0175f30a3ac0d04c8b55a87f5f6c0df6679ac9d4a1745b9344bda89d8d0df38972a7c2feee38016430ec2d26869b0b
data/lib/publish.rb CHANGED
@@ -31,8 +31,8 @@ class RuneBlog::Publishing
31
31
 
32
32
  def system!(str)
33
33
  rc = system(str)
34
- puts "Running: #{str}"
35
- puts "Failed: #{str}" if ! rc
34
+ debug "Running: #{str}"
35
+ debug "Failed!\n " if ! rc
36
36
  rc
37
37
  end
38
38
 
@@ -40,13 +40,19 @@ class RuneBlog::Publishing
40
40
  dir = "#@docroot/#@path"
41
41
  result = system!("ssh #@user@#@server -x mkdir -p #{dir}")
42
42
  result = system!("ssh #@user@#@server -x mkdir -p #{dir}/../assets")
43
- list = files.join(' ')
44
- cmd = "scp #{list} #@user@#@server:#{dir} >/dev/null 2>/tmp/wtf"
45
- debug "cmd = #{cmd.inspect} - see /tmp/wtf"
46
- result = system!(cmd)
47
- cmd = "scp #{assets.join(' ')} #@user@#@server:#{dir}/../assets >/dev/null 2>/tmp/wtf2"
48
- result = system!(cmd)
49
- raise PublishError if !result
43
+ files.each do |file|
44
+ dest = "#@user@#@server:#{dir}"
45
+ file.gsub!(/\/\//, "/") # weird... :-/
46
+ dest.gsub!(/\/\//, "/") # weird... :-/
47
+ cmd = "scp -r #{file} #{dest} >/dev/null 2>/tmp/wtf"
48
+ debug "cmd = #{cmd.inspect} - see /tmp/wtf"
49
+ result = system!(cmd) || puts("\n Could not copy #{file} to #{dest}")
50
+ end
51
+ unless assets.empty?
52
+ cmd = "scp #{assets.join(' ')} #@user@#@server:#{dir}/../assets >/dev/null 2>/tmp/wtf2"
53
+ result = system!(cmd)
54
+ raise PublishError if !result
55
+ end
50
56
  dump(files, "#{@blog.view.dir}/last_published")
51
57
  true
52
58
  end
data/lib/repl.rb CHANGED
@@ -135,7 +135,7 @@ module RuneBlog::REPL
135
135
  else
136
136
  if @blog.view?(arg)
137
137
  @blog.view = arg # reads config
138
- output red("View: ") + bold(@blog.view.name.to_s) # FIXME?
138
+ output "View: " + @blog.view.name.to_s
139
139
  puts "\n ", fx(arg, :bold), "\n" unless testing
140
140
  end
141
141
  end
@@ -239,7 +239,7 @@ module RuneBlog::REPL
239
239
  puts unless testing
240
240
  puts " ", fx(str, :bold) unless testing
241
241
  if posts.empty?
242
- output! bold("No posts")
242
+ output! "No posts"
243
243
  puts fx(" No posts", :bold) unless testing
244
244
  else
245
245
  posts.each do |post|
@@ -1,6 +1,6 @@
1
1
 
2
2
  class RuneBlog
3
- VERSION = "0.1.26"
3
+ VERSION = "0.1.27"
4
4
 
5
5
  Path = File.expand_path(File.join(File.dirname(__FILE__)))
6
6
  end
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.26
4
+ version: 0.1.27
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hal Fulton