wunderbar 0.10.4 → 0.10.5

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.
@@ -192,14 +192,14 @@ module Wunderbar
192
192
  end
193
193
 
194
194
  # insert verbatim
195
- def <<(string)
196
- if not String === string or string.include? '<' or string.include? '&'
195
+ def <<(data)
196
+ if not String === data or data.include? '<' or data.include? '&'
197
197
  require 'nokogiri'
198
- string = Nokogiri::HTML::fragment(string.to_s).to_xml
198
+ data = Nokogiri::HTML::fragment(data.to_s).to_xml
199
199
  end
200
200
 
201
201
  # fix CDATA in most cases (notably scripts)
202
- string.gsub!(/<!\[CDATA\[(.*?)\]\]>/m) do |cdata|
202
+ data.gsub!(/<!\[CDATA\[(.*?)\]\]>/m) do |cdata|
203
203
  if $1.include? '<' or $1.include? '&'
204
204
  "//<![CDATA[\n#{$1}\n//]]>"
205
205
  else
@@ -208,15 +208,15 @@ module Wunderbar
208
208
  end
209
209
 
210
210
  # fix CDATA for style elements
211
- string.gsub!(/<style>\/\/<!\[CDATA\[\n(.*?)\s+\/\/\]\]>/m) do |cdata|
212
- if $1.include? '<' or $1.include? '&'
213
- "<style>/*<![CDATA[*/\n#{$1.gsub("\n\Z",'')}\n/*]]>*/"
211
+ data.gsub!(/<style([^>])*>\/\/<!\[CDATA\[\n(.*?)\s+\/\/\]\]>/m) do |cdata|
212
+ if $2.include? '<' or $2.include? '&'
213
+ "<style#{$1}>/*<![CDATA[*/\n#{$2.gsub("\n\Z",'')}\n/*]]>*/"
214
214
  else
215
215
  $1
216
216
  end
217
217
  end
218
218
 
219
- @_builder << string.to_s
219
+ @_builder << data
220
220
  rescue LoadError
221
221
  @_builder << string
222
222
  end
@@ -2,7 +2,7 @@ module Wunderbar
2
2
  module VERSION #:nodoc:
3
3
  MAJOR = 0
4
4
  MINOR = 10
5
- TINY = 4
5
+ TINY = 5
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.10.4"
5
+ s.version = "0.10.5"
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"]
@@ -12,7 +12,7 @@ Gem::Specification.new do |s|
12
12
  s.files = ["wunderbar.gemspec", "README.md", "COPYING", "lib/wunderbar.rb", "lib/wunderbar", "lib/wunderbar/installation.rb", "lib/wunderbar/html-methods.rb", "lib/wunderbar/job-control.rb", "lib/wunderbar/server.rb", "lib/wunderbar/logger.rb", "lib/wunderbar/rack.rb", "lib/wunderbar/builder.rb", "lib/wunderbar/sinatra.rb", "lib/wunderbar/environment.rb", "lib/wunderbar/cgi-methods.rb", "lib/wunderbar/cssproxy.rb", "lib/wunderbar/version.rb"]
13
13
  s.homepage = "http://github.com/rubys/wunderbar"
14
14
  s.require_paths = ["lib"]
15
- s.rubygems_version = "1.8.15"
15
+ s.rubygems_version = "1.8.21"
16
16
  s.summary = "HTML Generator and CGI application support"
17
17
 
18
18
  if s.respond_to? :specification_version then
metadata CHANGED
@@ -1,47 +1,60 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: wunderbar
3
- version: !ruby/object:Gem::Version
4
- version: 0.10.4
3
+ version: !ruby/object:Gem::Version
4
+ hash: 61
5
5
  prerelease:
6
+ segments:
7
+ - 0
8
+ - 10
9
+ - 5
10
+ version: 0.10.5
6
11
  platform: ruby
7
- authors:
12
+ authors:
8
13
  - Sam Ruby
9
14
  autorequire:
10
15
  bindir: bin
11
16
  cert_chain: []
12
- date: 2012-04-15 00:00:00.000000000Z
13
- dependencies:
14
- - !ruby/object:Gem::Dependency
17
+
18
+ date: 2012-04-15 00:00:00 Z
19
+ dependencies:
20
+ - !ruby/object:Gem::Dependency
15
21
  name: builder
16
- requirement: &13584540 !ruby/object:Gem::Requirement
22
+ prerelease: false
23
+ requirement: &id001 !ruby/object:Gem::Requirement
17
24
  none: false
18
- requirements:
19
- - - ! '>='
20
- - !ruby/object:Gem::Version
21
- version: '3.0'
25
+ requirements:
26
+ - - ">="
27
+ - !ruby/object:Gem::Version
28
+ hash: 7
29
+ segments:
30
+ - 3
31
+ - 0
32
+ version: "3.0"
22
33
  type: :runtime
23
- prerelease: false
24
- version_requirements: *13584540
25
- - !ruby/object:Gem::Dependency
34
+ version_requirements: *id001
35
+ - !ruby/object:Gem::Dependency
26
36
  name: json
27
- requirement: &13583500 !ruby/object:Gem::Requirement
37
+ prerelease: false
38
+ requirement: &id002 !ruby/object:Gem::Requirement
28
39
  none: false
29
- requirements:
30
- - - ! '>='
31
- - !ruby/object:Gem::Version
32
- version: '0'
40
+ requirements:
41
+ - - ">="
42
+ - !ruby/object:Gem::Version
43
+ hash: 3
44
+ segments:
45
+ - 0
46
+ version: "0"
33
47
  type: :runtime
34
- prerelease: false
35
- version_requirements: *13583500
36
- description: ! " Wunderbar makes it easy to produce valid HTML5, wellformed XHTML,
37
- Unicode\n (utf-8), consistently indented, readable applications. This includes\n
38
- \ output that conforms to the Polyglot specification and the emerging\n results
39
- from the XML Error Recovery Community Group.\n"
48
+ version_requirements: *id002
49
+ description: " Wunderbar makes it easy to produce valid HTML5, wellformed XHTML, Unicode\n (utf-8), consistently indented, readable applications. This includes\n output that conforms to the Polyglot specification and the emerging\n results from the XML Error Recovery Community Group.\n"
40
50
  email: rubys@intertwingly.net
41
51
  executables: []
52
+
42
53
  extensions: []
54
+
43
55
  extra_rdoc_files: []
44
- files:
56
+
57
+ files:
45
58
  - wunderbar.gemspec
46
59
  - README.md
47
60
  - COPYING
@@ -60,26 +73,36 @@ files:
60
73
  - lib/wunderbar/version.rb
61
74
  homepage: http://github.com/rubys/wunderbar
62
75
  licenses: []
76
+
63
77
  post_install_message:
64
78
  rdoc_options: []
65
- require_paths:
79
+
80
+ require_paths:
66
81
  - lib
67
- required_ruby_version: !ruby/object:Gem::Requirement
82
+ required_ruby_version: !ruby/object:Gem::Requirement
68
83
  none: false
69
- requirements:
70
- - - ! '>='
71
- - !ruby/object:Gem::Version
72
- version: '0'
73
- required_rubygems_version: !ruby/object:Gem::Requirement
84
+ requirements:
85
+ - - ">="
86
+ - !ruby/object:Gem::Version
87
+ hash: 3
88
+ segments:
89
+ - 0
90
+ version: "0"
91
+ required_rubygems_version: !ruby/object:Gem::Requirement
74
92
  none: false
75
- requirements:
76
- - - ! '>='
77
- - !ruby/object:Gem::Version
78
- version: '0'
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ hash: 3
97
+ segments:
98
+ - 0
99
+ version: "0"
79
100
  requirements: []
101
+
80
102
  rubyforge_project:
81
- rubygems_version: 1.8.15
103
+ rubygems_version: 1.8.21
82
104
  signing_key:
83
105
  specification_version: 3
84
106
  summary: HTML Generator and CGI application support
85
107
  test_files: []
108
+