wunderbar 0.14.6 → 0.14.7
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/wunderbar/server.rb +15 -0
- data/lib/wunderbar/version.rb +1 -1
- data/wunderbar.gemspec +4 -4
- metadata +70 -57
data/lib/wunderbar/server.rb
CHANGED
@@ -77,6 +77,21 @@ else
|
|
77
77
|
env['REQUEST_METHOD'].to_s.downcase == http_method
|
78
78
|
end
|
79
79
|
end
|
80
|
+
|
81
|
+
# return only headers or content when run from the command line
|
82
|
+
if not ENV['REQUEST_METHOD']
|
83
|
+
def out(headers, &block)
|
84
|
+
if ARGV.delete('--head')
|
85
|
+
print "HTTP/1.1 #{headers.delete('status') || '200 OK'}\r\n"
|
86
|
+
require 'time'
|
87
|
+
headers['Date'] = Time.now.utc.rfc2822.sub(/-0000$/, 'GMT')
|
88
|
+
headers['Content-Length'] = block.call.bytesize
|
89
|
+
print header(headers)
|
90
|
+
else
|
91
|
+
print block.call
|
92
|
+
end
|
93
|
+
end
|
94
|
+
end
|
80
95
|
end
|
81
96
|
|
82
97
|
# get arguments if CGI couldn't find any...
|
data/lib/wunderbar/version.rb
CHANGED
data/wunderbar.gemspec
CHANGED
@@ -2,17 +2,17 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = "wunderbar"
|
5
|
-
s.version = "0.14.
|
5
|
+
s.version = "0.14.7"
|
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"]
|
9
|
-
s.date = "2012-05-
|
9
|
+
s.date = "2012-05-11"
|
10
10
|
s.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"
|
11
11
|
s.email = "rubys@intertwingly.net"
|
12
|
-
s.files = ["wunderbar.gemspec", "README.md", "COPYING", "lib/wunderbar.rb", "lib/wunderbar", "lib/wunderbar/
|
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/websocket.rb", "lib/wunderbar/sinatra.rb", "lib/wunderbar/environment.rb", "lib/wunderbar/rails.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
|
+
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,97 +1,110 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: wunderbar
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
hash: 41
|
5
5
|
prerelease:
|
6
|
+
segments:
|
7
|
+
- 0
|
8
|
+
- 14
|
9
|
+
- 7
|
10
|
+
version: 0.14.7
|
6
11
|
platform: ruby
|
7
|
-
authors:
|
12
|
+
authors:
|
8
13
|
- Sam Ruby
|
9
14
|
autorequire:
|
10
15
|
bindir: bin
|
11
16
|
cert_chain: []
|
12
|
-
|
13
|
-
|
14
|
-
|
17
|
+
|
18
|
+
date: 2012-05-11 00:00:00 Z
|
19
|
+
dependencies:
|
20
|
+
- !ruby/object:Gem::Dependency
|
15
21
|
name: builder
|
16
|
-
requirement: !ruby/object:Gem::Requirement
|
17
|
-
none: false
|
18
|
-
requirements:
|
19
|
-
- - ! '>='
|
20
|
-
- !ruby/object:Gem::Version
|
21
|
-
version: '3.0'
|
22
|
-
type: :runtime
|
23
22
|
prerelease: false
|
24
|
-
|
25
|
-
none: false
|
26
|
-
requirements:
|
27
|
-
- - ! '>='
|
28
|
-
- !ruby/object:Gem::Version
|
29
|
-
version: '3.0'
|
30
|
-
- !ruby/object:Gem::Dependency
|
31
|
-
name: json
|
32
|
-
requirement: !ruby/object:Gem::Requirement
|
23
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
33
24
|
none: false
|
34
|
-
requirements:
|
35
|
-
- -
|
36
|
-
- !ruby/object:Gem::Version
|
37
|
-
|
25
|
+
requirements:
|
26
|
+
- - ">="
|
27
|
+
- !ruby/object:Gem::Version
|
28
|
+
hash: 7
|
29
|
+
segments:
|
30
|
+
- 3
|
31
|
+
- 0
|
32
|
+
version: "3.0"
|
38
33
|
type: :runtime
|
34
|
+
version_requirements: *id001
|
35
|
+
- !ruby/object:Gem::Dependency
|
36
|
+
name: json
|
39
37
|
prerelease: false
|
40
|
-
|
38
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
41
39
|
none: false
|
42
|
-
requirements:
|
43
|
-
- -
|
44
|
-
- !ruby/object:Gem::Version
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
40
|
+
requirements:
|
41
|
+
- - ">="
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
hash: 3
|
44
|
+
segments:
|
45
|
+
- 0
|
46
|
+
version: "0"
|
47
|
+
type: :runtime
|
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"
|
50
50
|
email: rubys@intertwingly.net
|
51
51
|
executables: []
|
52
|
+
|
52
53
|
extensions: []
|
54
|
+
|
53
55
|
extra_rdoc_files: []
|
54
|
-
|
56
|
+
|
57
|
+
files:
|
55
58
|
- wunderbar.gemspec
|
56
59
|
- README.md
|
57
60
|
- COPYING
|
58
61
|
- lib/wunderbar.rb
|
59
|
-
- lib/wunderbar/version.rb
|
60
62
|
- lib/wunderbar/installation.rb
|
61
|
-
- lib/wunderbar/
|
62
|
-
- lib/wunderbar/
|
63
|
+
- lib/wunderbar/html-methods.rb
|
64
|
+
- lib/wunderbar/job-control.rb
|
65
|
+
- lib/wunderbar/server.rb
|
63
66
|
- lib/wunderbar/logger.rb
|
67
|
+
- lib/wunderbar/rack.rb
|
64
68
|
- lib/wunderbar/builder.rb
|
69
|
+
- lib/wunderbar/websocket.rb
|
65
70
|
- lib/wunderbar/sinatra.rb
|
66
|
-
- lib/wunderbar/rails.rb
|
67
|
-
- lib/wunderbar/server.rb
|
68
|
-
- lib/wunderbar/html-methods.rb
|
69
|
-
- lib/wunderbar/job-control.rb
|
70
71
|
- lib/wunderbar/environment.rb
|
72
|
+
- lib/wunderbar/rails.rb
|
71
73
|
- lib/wunderbar/cgi-methods.rb
|
72
|
-
- lib/wunderbar/
|
74
|
+
- lib/wunderbar/cssproxy.rb
|
75
|
+
- lib/wunderbar/version.rb
|
73
76
|
homepage: http://github.com/rubys/wunderbar
|
74
77
|
licenses: []
|
78
|
+
|
75
79
|
post_install_message:
|
76
80
|
rdoc_options: []
|
77
|
-
|
81
|
+
|
82
|
+
require_paths:
|
78
83
|
- lib
|
79
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
84
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
80
85
|
none: false
|
81
|
-
requirements:
|
82
|
-
- -
|
83
|
-
- !ruby/object:Gem::Version
|
84
|
-
|
85
|
-
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
hash: 3
|
90
|
+
segments:
|
91
|
+
- 0
|
92
|
+
version: "0"
|
93
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
86
94
|
none: false
|
87
|
-
requirements:
|
88
|
-
- -
|
89
|
-
- !ruby/object:Gem::Version
|
90
|
-
|
95
|
+
requirements:
|
96
|
+
- - ">="
|
97
|
+
- !ruby/object:Gem::Version
|
98
|
+
hash: 3
|
99
|
+
segments:
|
100
|
+
- 0
|
101
|
+
version: "0"
|
91
102
|
requirements: []
|
103
|
+
|
92
104
|
rubyforge_project:
|
93
|
-
rubygems_version: 1.8.
|
105
|
+
rubygems_version: 1.8.21
|
94
106
|
signing_key:
|
95
107
|
specification_version: 3
|
96
108
|
summary: HTML Generator and CGI application support
|
97
109
|
test_files: []
|
110
|
+
|