wunderbar 0.16.5 → 0.16.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -172,6 +172,17 @@ module Wunderbar
172
172
  end
173
173
  end
174
174
 
175
+ def _p(*args, &block)
176
+ if args.length >= 1 and String === args.first and args.first.start_with? "\n"
177
+ text = args.shift
178
+ @x.tag! :p, *args do
179
+ @x.indented_text! text
180
+ end
181
+ else
182
+ super
183
+ end
184
+ end
185
+
175
186
  def _svg(*args, &block)
176
187
  args << {} if args.empty?
177
188
  args.first['xmlns'] = 'http://www.w3.org/2000/svg' if Hash === args.first
@@ -66,9 +66,11 @@ else
66
66
  end
67
67
 
68
68
  $HOME = ENV['HOME']
69
- $HOME ||= Dir.home($USER) rescue nil
70
- $HOME ||= File.expand_path("~#{$USER}") rescue nil
71
- $HOME = ENV['DOCUMENT_ROOT'] if not $HOME or not File.exist? $HOME
69
+ if $HOME.nil? and $USER == Etc.getlogin
70
+ $HOME ||= Dir.home($USER) rescue nil
71
+ $HOME ||= File.expand_path("~#{$USER}") rescue nil
72
+ end
73
+ $HOME = ENV['DOCUMENT_ROOT'] if $HOME.nil? or not File.exist? $HOME
72
74
  ENV['HOME'] = $HOME
73
75
 
74
76
  at_exit do
@@ -2,7 +2,7 @@ module Wunderbar
2
2
  module VERSION #:nodoc:
3
3
  MAJOR = 0
4
4
  MINOR = 16
5
- TINY = 5
5
+ TINY = 6
6
6
 
7
7
  STRING = [MAJOR, MINOR, TINY].join('.')
8
8
  end
data/wunderbar.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = "wunderbar"
5
- s.version = "0.16.5"
5
+ s.version = "0.16.6"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Sam Ruby"]
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wunderbar
3
3
  version: !ruby/object:Gem::Version
4
- hash: 85
4
+ hash: 83
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 16
9
- - 5
10
- version: 0.16.5
9
+ - 6
10
+ version: 0.16.6
11
11
  platform: ruby
12
12
  authors:
13
13
  - Sam Ruby