middleman-minify-html 3.0.0.beta.2 → 3.0.0.beta.3

Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile CHANGED
@@ -1,10 +1,10 @@
1
- source "http://rubygems.org"
1
+ source :rubygems
2
2
 
3
- # git "git://github.com/middleman/middleman.git" do
4
- # # gem "middleman"
5
- # gem "middleman-core"
6
- # # gem "middleman-more"
7
- # end
3
+ git "git://github.com/middleman/middleman.git" do
4
+ # gem "middleman"
5
+ gem "middleman-core"
6
+ # gem "middleman-more"
7
+ end
8
8
 
9
9
  # Specify your gem's dependencies in middleman-blog.gemspec
10
10
  gemspec
@@ -1,6 +1,6 @@
1
1
  require "middleman-core"
2
2
 
3
- ::Middleman::Extensions.register(:minify_html, ">= 3.0.0.beta.2") do
3
+ ::Middleman::Extensions.register(:minify_html, ">= 3.0.0.beta.3") do
4
4
  require "middleman-minify-html/extension"
5
5
  ::Middleman::MinifyHtml
6
6
  end
@@ -36,7 +36,7 @@ module Middleman
36
36
  path = env["PATH_INFO"]
37
37
 
38
38
  if path.end_with?('.html')
39
- uncompressed_source = extract_response_text(response)
39
+ uncompressed_source = ::Middleman::Util.extract_response_text(response)
40
40
  minified_html = @compressor.compress(uncompressed_source)
41
41
 
42
42
  headers["Content-Length"] = ::Rack::Utils.bytesize(minified_html).to_s
@@ -45,24 +45,6 @@ module Middleman
45
45
 
46
46
  [status, headers, response]
47
47
  end
48
-
49
- private
50
-
51
- def extract_response_text(response)
52
- case(response)
53
- when String
54
- response
55
- when Array
56
- response.join
57
- when Rack::Response
58
- response.body.join
59
- when Rack::File
60
- File.read(response.path)
61
- else
62
- response.to_s
63
- end
64
- end
65
- end
66
-
48
+ end
67
49
  end
68
50
  end
@@ -1,5 +1,5 @@
1
1
  module Middleman
2
2
  module MinifyHtml
3
- VERSION = "3.0.0.beta.2"
3
+ VERSION = "3.0.0.beta.3"
4
4
  end
5
5
  end
@@ -19,6 +19,6 @@ Gem::Specification.new do |s|
19
19
  s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
20
20
  s.require_paths = ["lib"]
21
21
 
22
- s.add_runtime_dependency("middleman-core", [">= 3.0.0.beta.2"])
22
+ s.add_runtime_dependency("middleman-core", [">= 3.0.0.beta.3"])
23
23
  s.add_runtime_dependency("html_compressor")
24
24
  end
metadata CHANGED
@@ -1,66 +1,45 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: middleman-minify-html
3
- version: !ruby/object:Gem::Version
4
- hash: 62196423
3
+ version: !ruby/object:Gem::Version
4
+ version: 3.0.0.beta.3
5
5
  prerelease: 6
6
- segments:
7
- - 3
8
- - 0
9
- - 0
10
- - beta
11
- - 2
12
- version: 3.0.0.beta.2
13
6
  platform: ruby
14
- authors:
7
+ authors:
15
8
  - Thomas Reynolds
16
9
  autorequire:
17
10
  bindir: bin
18
11
  cert_chain: []
19
-
20
- date: 2012-04-23 00:00:00 Z
21
- dependencies:
22
- - !ruby/object:Gem::Dependency
23
- type: :runtime
12
+ date: 2012-05-21 00:00:00.000000000Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
24
15
  name: middleman-core
25
- version_requirements: &id001 !ruby/object:Gem::Requirement
16
+ requirement: &70134298159860 !ruby/object:Gem::Requirement
26
17
  none: false
27
- requirements:
28
- - - ">="
29
- - !ruby/object:Gem::Version
30
- hash: 62196423
31
- segments:
32
- - 3
33
- - 0
34
- - 0
35
- - beta
36
- - 2
37
- version: 3.0.0.beta.2
38
- prerelease: false
39
- requirement: *id001
40
- - !ruby/object:Gem::Dependency
18
+ requirements:
19
+ - - ! '>='
20
+ - !ruby/object:Gem::Version
21
+ version: 3.0.0.beta.3
41
22
  type: :runtime
23
+ prerelease: false
24
+ version_requirements: *70134298159860
25
+ - !ruby/object:Gem::Dependency
42
26
  name: html_compressor
43
- version_requirements: &id002 !ruby/object:Gem::Requirement
27
+ requirement: &70134298159440 !ruby/object:Gem::Requirement
44
28
  none: false
45
- requirements:
46
- - - ">="
47
- - !ruby/object:Gem::Version
48
- hash: 3
49
- segments:
50
- - 0
51
- version: "0"
29
+ requirements:
30
+ - - ! '>='
31
+ - !ruby/object:Gem::Version
32
+ version: '0'
33
+ type: :runtime
52
34
  prerelease: false
53
- requirement: *id002
35
+ version_requirements: *70134298159440
54
36
  description: A html whitespace minifier for Middleman
55
- email:
37
+ email:
56
38
  - me@tdreyno.com
57
39
  executables: []
58
-
59
40
  extensions: []
60
-
61
41
  extra_rdoc_files: []
62
-
63
- files:
42
+ files:
64
43
  - .gitignore
65
44
  - .travis.yml
66
45
  - Gemfile
@@ -78,39 +57,31 @@ files:
78
57
  - middleman-minify-html.gemspec
79
58
  homepage: https://github.com/middleman/middleman-minify-html
80
59
  licenses: []
81
-
82
60
  post_install_message:
83
61
  rdoc_options: []
84
-
85
- require_paths:
62
+ require_paths:
86
63
  - lib
87
- required_ruby_version: !ruby/object:Gem::Requirement
64
+ required_ruby_version: !ruby/object:Gem::Requirement
88
65
  none: false
89
- requirements:
90
- - - ">="
91
- - !ruby/object:Gem::Version
92
- hash: 3
93
- segments:
66
+ requirements:
67
+ - - ! '>='
68
+ - !ruby/object:Gem::Version
69
+ version: '0'
70
+ segments:
94
71
  - 0
95
- version: "0"
96
- required_rubygems_version: !ruby/object:Gem::Requirement
72
+ hash: 2516722774850114131
73
+ required_rubygems_version: !ruby/object:Gem::Requirement
97
74
  none: false
98
- requirements:
99
- - - ">"
100
- - !ruby/object:Gem::Version
101
- hash: 25
102
- segments:
103
- - 1
104
- - 3
105
- - 1
75
+ requirements:
76
+ - - ! '>'
77
+ - !ruby/object:Gem::Version
106
78
  version: 1.3.1
107
79
  requirements: []
108
-
109
80
  rubyforge_project: middleman-minify-html
110
- rubygems_version: 1.8.18
81
+ rubygems_version: 1.8.10
111
82
  signing_key:
112
83
  specification_version: 3
113
84
  summary: A html whitespace minifier for Middleman
114
- test_files:
85
+ test_files:
115
86
  - features/preview.feature
116
87
  - features/support/env.rb