sprockets 2.0.5 → 2.1.0.beta

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of sprockets might be problematic. Click here for more details.

@@ -66,24 +66,18 @@ module Sprockets
66
66
 
67
67
  # Cache `find_asset` calls
68
68
  def find_asset(path, options = {})
69
+ options[:bundle] = true unless options.key?(:bundle)
70
+
69
71
  # Ensure inmemory cached assets are still fresh on every lookup
70
- if (asset = @assets[path.to_s]) && asset.fresh?
72
+ if (asset = @assets[cache_key_for(path, options)]) && asset.fresh?(self)
71
73
  asset
72
- elsif asset = super
73
- @assets[path.to_s] = @assets[asset.pathname.to_s] = asset
74
+ elsif asset = index.find_asset(path, options)
75
+ # Cache is pushed upstream by Index#find_asset
74
76
  asset
75
77
  end
76
78
  end
77
79
 
78
80
  protected
79
- # Cache asset building in persisted cache.
80
- def build_asset(path, pathname, options)
81
- # Persisted cache
82
- cache_asset(pathname.to_s) do
83
- super
84
- end
85
- end
86
-
87
81
  def expire_index!
88
82
  # Clear digest to be recomputed
89
83
  @digest = nil
@@ -7,6 +7,7 @@ module Sprockets
7
7
  class EncodingError < Error; end
8
8
  class FileNotFound < Error; end
9
9
  class FileOutsidePaths < Error; end
10
+ class UnserializeError < Error; end
10
11
 
11
12
  module EngineError
12
13
  attr_accessor :sprockets_annotation
@@ -12,6 +12,8 @@ module Sprockets
12
12
  # `Environment#index`.
13
13
  class Index < Base
14
14
  def initialize(environment)
15
+ @environment = environment
16
+
15
17
  # Copy environment attributes
16
18
  @logger = environment.logger
17
19
  @context_class = environment.context_class
@@ -37,17 +39,32 @@ module Sprockets
37
39
  end
38
40
 
39
41
  # Cache calls to `file_digest`
40
- def file_digest(pathname, data = nil)
41
- memoize(@digests, pathname.to_s) { super }
42
+ def file_digest(pathname)
43
+ key = pathname.to_s
44
+ if @digests.key?(key)
45
+ @digests[key]
46
+ else
47
+ @digests[key] = super
48
+ end
42
49
  end
43
50
 
44
51
  # Cache `find_asset` calls
45
52
  def find_asset(path, options = {})
46
- if asset = @assets[path.to_s]
53
+ options[:bundle] = true unless options.key?(:bundle)
54
+ if asset = @assets[cache_key_for(path, options)]
47
55
  asset
48
56
  elsif asset = super
49
- # Cache at logical path and expanded path
50
- @assets[path.to_s] = @assets[asset.pathname.to_s] = asset
57
+ logical_path_cache_key = cache_key_for(path, options)
58
+ full_path_cache_key = cache_key_for(asset.pathname, options)
59
+
60
+ # Cache on Index
61
+ @assets[logical_path_cache_key] = @assets[full_path_cache_key] = asset
62
+
63
+ # Push cache upstream to Environment
64
+ @environment.instance_eval do
65
+ @assets[logical_path_cache_key] = @assets[full_path_cache_key] = asset
66
+ end
67
+
51
68
  asset
52
69
  end
53
70
  end
@@ -62,18 +79,17 @@ module Sprockets
62
79
  # Cache asset building in memory and in persisted cache.
63
80
  def build_asset(path, pathname, options)
64
81
  # Memory cache
65
- memoize(@assets, pathname.to_s) do
66
- # Persisted cache
67
- cache_asset(pathname.to_s) do
68
- super
82
+ key = cache_key_for(pathname, options)
83
+ if @assets.key?(key)
84
+ @assets[key]
85
+ else
86
+ @assets[key] = begin
87
+ # Persisted cache
88
+ cache_asset(key) do
89
+ super
90
+ end
69
91
  end
70
92
  end
71
93
  end
72
-
73
- private
74
- # Simple memoize helper that stores `nil` values
75
- def memoize(hash, key)
76
- hash.key?(key) ? hash[key] : hash[key] = yield
77
- end
78
94
  end
79
95
  end
@@ -0,0 +1,148 @@
1
+ require 'sprockets/asset'
2
+ require 'sprockets/utils'
3
+
4
+ module Sprockets
5
+ class ProcessedAsset < Asset
6
+ def initialize(environment, logical_path, pathname)
7
+ super
8
+
9
+ start_time = Time.now.to_f
10
+
11
+ context = environment.context_class.new(environment, logical_path, pathname)
12
+ @source = context.evaluate(pathname)
13
+ @length = Rack::Utils.bytesize(source)
14
+ @digest = environment.digest.update(source).hexdigest
15
+
16
+ build_required_assets(environment, context)
17
+ build_dependency_paths(environment, context)
18
+
19
+ @dependency_digest = compute_dependency_digest(environment)
20
+
21
+ elapsed_time = ((Time.now.to_f - start_time) * 1000).to_i
22
+ environment.logger.info "Compiled #{logical_path} (#{elapsed_time}ms) (pid #{Process.pid})"
23
+ end
24
+
25
+ # Interal: Used to check equality
26
+ attr_reader :dependency_digest
27
+
28
+ attr_reader :source
29
+
30
+ # Initialize `BundledAsset` from serialized `Hash`.
31
+ def init_with(environment, coder)
32
+ super
33
+
34
+ @source = coder['source']
35
+ @dependency_digest = coder['dependency_digest']
36
+
37
+ @required_assets = coder['required_paths'].map { |p|
38
+ p = expand_root_path(p)
39
+
40
+ unless environment.paths.detect { |path| p[path] }
41
+ raise UnserializeError, "#{p} isn't in paths"
42
+ end
43
+
44
+ p == pathname.to_s ? self : environment.find_asset(p, :bundle => false)
45
+ }
46
+ @dependency_paths = coder['dependency_paths'].map { |h|
47
+ DependencyFile.new(expand_root_path(h['path']), h['mtime'], h['digest'])
48
+ }
49
+ end
50
+
51
+ # Serialize custom attributes in `BundledAsset`.
52
+ def encode_with(coder)
53
+ super
54
+
55
+ coder['source'] = source
56
+ coder['dependency_digest'] = dependency_digest
57
+
58
+ coder['required_paths'] = required_assets.map { |a|
59
+ relativize_root_path(a.pathname).to_s
60
+ }
61
+ coder['dependency_paths'] = dependency_paths.map { |d|
62
+ { 'path' => relativize_root_path(d.pathname).to_s,
63
+ 'mtime' => d.mtime.iso8601,
64
+ 'digest' => d.digest }
65
+ }
66
+ end
67
+
68
+ # Checks if Asset is stale by comparing the actual mtime and
69
+ # digest to the inmemory model.
70
+ def fresh?(environment)
71
+ # Check freshness of all declared dependencies
72
+ @dependency_paths.all? { |dep| dependency_fresh?(environment, dep) }
73
+ end
74
+
75
+ protected
76
+ class DependencyFile < Struct.new(:pathname, :mtime, :digest)
77
+ def initialize(pathname, mtime, digest)
78
+ pathname = Pathname.new(pathname) unless pathname.is_a?(Pathname)
79
+ mtime = Time.parse(mtime) if mtime.is_a?(String)
80
+ super
81
+ end
82
+
83
+ def eql?(other)
84
+ other.is_a?(DependencyFile) &&
85
+ pathname.eql?(other.pathname) &&
86
+ mtime.eql?(other.mtime) &&
87
+ digest.eql?(other.digest)
88
+ end
89
+
90
+ def hash
91
+ pathname.to_s.hash
92
+ end
93
+ end
94
+
95
+ private
96
+ def build_required_assets(environment, context)
97
+ @required_assets = []
98
+ required_assets_cache = {}
99
+
100
+ (context._required_paths + [pathname.to_s]).each do |path|
101
+ if path == self.pathname.to_s
102
+ unless required_assets_cache[self]
103
+ required_assets_cache[self] = true
104
+ @required_assets << self
105
+ end
106
+ elsif asset = environment.find_asset(path, :bundle => false)
107
+ asset.required_assets.each do |asset_dependency|
108
+ unless required_assets_cache[asset_dependency]
109
+ required_assets_cache[asset_dependency] = true
110
+ @required_assets << asset_dependency
111
+ end
112
+ end
113
+ end
114
+ end
115
+
116
+ required_assets_cache.clear
117
+ required_assets_cache = nil
118
+ end
119
+
120
+ def build_dependency_paths(environment, context)
121
+ dependency_paths = {}
122
+
123
+ context._dependency_paths.each do |path|
124
+ dep = DependencyFile.new(path, environment.stat(path).mtime, environment.file_digest(path).hexdigest)
125
+ dependency_paths[dep] = true
126
+ end
127
+
128
+ context._dependency_assets.each do |path|
129
+ if path == self.pathname.to_s
130
+ dep = DependencyFile.new(pathname, environment.stat(path).mtime, environment.file_digest(path).hexdigest)
131
+ dependency_paths[dep] = true
132
+ elsif asset = environment.find_asset(path, :bundle => false)
133
+ asset.dependency_paths.each do |d|
134
+ dependency_paths[d] = true
135
+ end
136
+ end
137
+ end
138
+
139
+ @dependency_paths = dependency_paths.keys
140
+ end
141
+
142
+ def compute_dependency_digest(environment)
143
+ required_assets.inject(environment.digest) { |digest, asset|
144
+ digest.update asset.digest
145
+ }.hexdigest
146
+ end
147
+ end
148
+ end
@@ -25,6 +25,11 @@ module Sprockets
25
25
 
26
26
  msg = "Served asset #{env['PATH_INFO']} -"
27
27
 
28
+ # URLs containing a `".."` are rejected for security reasons.
29
+ if forbidden_request?(env)
30
+ return forbidden_response
31
+ end
32
+
28
33
  # Mark session as "skipped" so no `Set-Cookie` header is set
29
34
  env['rack.session.options'] ||= {}
30
35
  env['rack.session.options'][:defer] = true
@@ -33,14 +38,13 @@ module Sprockets
33
38
  # Extract the path from everything after the leading slash
34
39
  path = unescape(env['PATH_INFO'].to_s.sub(/^\//, ''))
35
40
 
36
- # URLs containing a `".."` are rejected for security reasons.
37
- if forbidden_request?(path)
38
- return forbidden_response
41
+ # Strip fingerprint
42
+ if fingerprint = path_fingerprint(path)
43
+ path = path.sub("-#{fingerprint}", '')
39
44
  end
40
45
 
41
46
  # Look up the asset.
42
- asset = find_asset(path)
43
- asset.to_a if asset
47
+ asset = find_asset(path, :bundle => !body_only?(env))
44
48
 
45
49
  # `find_asset` returns nil if the asset doesn't exist
46
50
  if asset.nil?
@@ -82,12 +86,12 @@ module Sprockets
82
86
  end
83
87
 
84
88
  private
85
- def forbidden_request?(path)
89
+ def forbidden_request?(env)
86
90
  # Prevent access to files elsewhere on the file system
87
91
  #
88
92
  # http://example.org/assets/../../../etc/passwd
89
93
  #
90
- path.include?("..") || Pathname.new(path).absolute?
94
+ env["PATH_INFO"].include?("..")
91
95
  end
92
96
 
93
97
  # Returns a 403 Forbidden response tuple
@@ -193,11 +197,7 @@ module Sprockets
193
197
 
194
198
  # Returns a 200 OK response tuple
195
199
  def ok_response(asset, env)
196
- if body_only?(env)
197
- [ 200, headers(env, asset, Rack::Utils.bytesize(asset.body)), [asset.body] ]
198
- else
199
- [ 200, headers(env, asset, asset.length), asset ]
200
- end
200
+ [ 200, headers(env, asset, asset.length), asset ]
201
201
  end
202
202
 
203
203
  def headers(env, asset, length)
@@ -213,7 +213,7 @@ module Sprockets
213
213
 
214
214
  # If the request url contains a fingerprint, set a long
215
215
  # expires on the response
216
- if attributes_for(env["PATH_INFO"]).path_fingerprint
216
+ if path_fingerprint(env["PATH_INFO"])
217
217
  headers["Cache-Control"] << ", max-age=31536000"
218
218
 
219
219
  # Otherwise set `must-revalidate` since the asset could be modified.
@@ -223,6 +223,15 @@ module Sprockets
223
223
  end
224
224
  end
225
225
 
226
+ # Gets digest fingerprint.
227
+ #
228
+ # "foo-0aa2105d29558f3eb790d411d7d8fb66.js"
229
+ # # => "0aa2105d29558f3eb790d411d7d8fb66"
230
+ #
231
+ def path_fingerprint(path)
232
+ path[/-([0-9a-f]{7,40})\.[^.]+$/, 1]
233
+ end
234
+
226
235
  # URI.unescape is deprecated on 1.9. We need to use URI::Parser
227
236
  # if its available.
228
237
  if defined? URI::DEFAULT_PARSER
@@ -7,40 +7,17 @@ module Sprockets
7
7
  # any processing or concatenation. These are typical images and
8
8
  # other binary files.
9
9
  class StaticAsset < Asset
10
- # Define extra attributes to be serialized.
11
- def self.serialized_attributes
12
- super + %w( content_type mtime length digest )
13
- end
14
-
15
- def initialize(environment, logical_path, pathname, digest = nil)
16
- super(environment, logical_path, pathname)
17
- @digest = digest
18
- load!
19
- end
20
-
21
- # Returns file contents as its `body`.
22
- def body
10
+ # Returns file contents as its `source`.
11
+ def source
23
12
  # File is read everytime to avoid memory bloat of large binary files
24
13
  pathname.open('rb') { |f| f.read }
25
14
  end
26
15
 
27
- # Checks if Asset is fresh by comparing the actual mtime and
28
- # digest to the inmemory model.
29
- def fresh?
30
- # Check current mtime and digest
31
- dependency_fresh?('path' => pathname, 'mtime' => mtime, 'hexdigest' => digest)
32
- end
33
-
34
16
  # Implemented for Rack SendFile support.
35
17
  def to_path
36
18
  pathname.to_s
37
19
  end
38
20
 
39
- # `to_s` is aliased to body since static assets can't have any dependencies.
40
- def to_s
41
- body
42
- end
43
-
44
21
  # Save asset to disk.
45
22
  def write_to(filename, options = {})
46
23
  # Gzip contents if filename has '.gz'
@@ -74,13 +51,5 @@ module Sprockets
74
51
  # Ensure tmp file gets cleaned up
75
52
  FileUtils.rm("#{filename}+") if File.exist?("#{filename}+")
76
53
  end
77
-
78
- private
79
- def load!
80
- content_type
81
- mtime
82
- length
83
- digest
84
- end
85
54
  end
86
55
  end
@@ -86,29 +86,5 @@ module Sprockets
86
86
  def trail
87
87
  @trail
88
88
  end
89
-
90
- def find_asset_in_path(logical_path, options = {})
91
- # Strip fingerprint on logical path if there is one.
92
- # Not sure how valuable this feature is...
93
- if fingerprint = attributes_for(logical_path).path_fingerprint
94
- pathname = resolve(logical_path.to_s.sub("-#{fingerprint}", ''))
95
- else
96
- pathname = resolve(logical_path)
97
- end
98
- rescue FileNotFound
99
- nil
100
- else
101
- # Build the asset for the actual pathname
102
- asset = build_asset(logical_path, pathname, options)
103
-
104
- # Double check request fingerprint against actual digest
105
- # Again, not sure if this code path is even reachable
106
- if fingerprint && fingerprint != asset.digest
107
- logger.error "Nonexistent asset #{logical_path} @ #{fingerprint}"
108
- asset = nil
109
- end
110
-
111
- asset
112
- end
113
89
  end
114
90
  end
@@ -1,3 +1,3 @@
1
1
  module Sprockets
2
- VERSION = "2.0.5"
2
+ VERSION = "2.1.0.beta"
3
3
  end
metadata CHANGED
@@ -1,174 +1,193 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: sprockets
3
- version: !ruby/object:Gem::Version
4
- version: 2.0.5
3
+ version: !ruby/object:Gem::Version
4
+ hash: 31098217
5
+ prerelease: 6
6
+ segments:
7
+ - 2
8
+ - 1
9
+ - 0
10
+ - beta
11
+ version: 2.1.0.beta
5
12
  platform: ruby
6
- authors:
13
+ authors:
7
14
  - Sam Stephenson
8
15
  - Joshua Peek
9
16
  autorequire:
10
17
  bindir: bin
11
18
  cert_chain: []
12
- date: 2014-10-28 00:00:00.000000000 Z
13
- dependencies:
14
- - !ruby/object:Gem::Dependency
19
+
20
+ date: 2011-11-05 00:00:00 -05:00
21
+ default_executable:
22
+ dependencies:
23
+ - !ruby/object:Gem::Dependency
15
24
  name: hike
16
- requirement: !ruby/object:Gem::Requirement
17
- requirements:
18
- - - "~>"
19
- - !ruby/object:Gem::Version
20
- version: '1.2'
21
- type: :runtime
22
25
  prerelease: false
23
- version_requirements: !ruby/object:Gem::Requirement
24
- requirements:
25
- - - "~>"
26
- - !ruby/object:Gem::Version
27
- version: '1.2'
28
- - !ruby/object:Gem::Dependency
29
- name: rack
30
- requirement: !ruby/object:Gem::Requirement
31
- requirements:
32
- - - "~>"
33
- - !ruby/object:Gem::Version
34
- version: '1.0'
26
+ requirement: &id001 !ruby/object:Gem::Requirement
27
+ none: false
28
+ requirements:
29
+ - - ~>
30
+ - !ruby/object:Gem::Version
31
+ hash: 11
32
+ segments:
33
+ - 1
34
+ - 2
35
+ version: "1.2"
35
36
  type: :runtime
37
+ version_requirements: *id001
38
+ - !ruby/object:Gem::Dependency
39
+ name: rack
36
40
  prerelease: false
37
- version_requirements: !ruby/object:Gem::Requirement
38
- requirements:
39
- - - "~>"
40
- - !ruby/object:Gem::Version
41
- version: '1.0'
42
- - !ruby/object:Gem::Dependency
43
- name: tilt
44
- requirement: !ruby/object:Gem::Requirement
45
- requirements:
46
- - - "~>"
47
- - !ruby/object:Gem::Version
48
- version: '1.1'
49
- - - "!="
50
- - !ruby/object:Gem::Version
51
- version: 1.3.0
41
+ requirement: &id002 !ruby/object:Gem::Requirement
42
+ none: false
43
+ requirements:
44
+ - - ~>
45
+ - !ruby/object:Gem::Version
46
+ hash: 15
47
+ segments:
48
+ - 1
49
+ - 0
50
+ version: "1.0"
52
51
  type: :runtime
52
+ version_requirements: *id002
53
+ - !ruby/object:Gem::Dependency
54
+ name: tilt
53
55
  prerelease: false
54
- version_requirements: !ruby/object:Gem::Requirement
55
- requirements:
56
- - - "~>"
57
- - !ruby/object:Gem::Version
58
- version: '1.1'
56
+ requirement: &id003 !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ~>
60
+ - !ruby/object:Gem::Version
61
+ hash: 13
62
+ segments:
63
+ - 1
64
+ - 1
65
+ version: "1.1"
59
66
  - - "!="
60
- - !ruby/object:Gem::Version
67
+ - !ruby/object:Gem::Version
68
+ hash: 27
69
+ segments:
70
+ - 1
71
+ - 3
72
+ - 0
61
73
  version: 1.3.0
62
- - !ruby/object:Gem::Dependency
74
+ type: :runtime
75
+ version_requirements: *id003
76
+ - !ruby/object:Gem::Dependency
63
77
  name: coffee-script
64
- requirement: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - "~>"
67
- - !ruby/object:Gem::Version
68
- version: '2.0'
69
- type: :development
70
78
  prerelease: false
71
- version_requirements: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - "~>"
74
- - !ruby/object:Gem::Version
75
- version: '2.0'
76
- - !ruby/object:Gem::Dependency
77
- name: eco
78
- requirement: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - "~>"
81
- - !ruby/object:Gem::Version
82
- version: '1.0'
79
+ requirement: &id004 !ruby/object:Gem::Requirement
80
+ none: false
81
+ requirements:
82
+ - - ~>
83
+ - !ruby/object:Gem::Version
84
+ hash: 3
85
+ segments:
86
+ - 2
87
+ - 0
88
+ version: "2.0"
83
89
  type: :development
90
+ version_requirements: *id004
91
+ - !ruby/object:Gem::Dependency
92
+ name: eco
84
93
  prerelease: false
85
- version_requirements: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - "~>"
88
- - !ruby/object:Gem::Version
89
- version: '1.0'
90
- - !ruby/object:Gem::Dependency
91
- name: ejs
92
- requirement: !ruby/object:Gem::Requirement
93
- requirements:
94
- - - "~>"
95
- - !ruby/object:Gem::Version
96
- version: '1.0'
94
+ requirement: &id005 !ruby/object:Gem::Requirement
95
+ none: false
96
+ requirements:
97
+ - - ~>
98
+ - !ruby/object:Gem::Version
99
+ hash: 15
100
+ segments:
101
+ - 1
102
+ - 0
103
+ version: "1.0"
97
104
  type: :development
105
+ version_requirements: *id005
106
+ - !ruby/object:Gem::Dependency
107
+ name: ejs
98
108
  prerelease: false
99
- version_requirements: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - "~>"
102
- - !ruby/object:Gem::Version
103
- version: '1.0'
104
- - !ruby/object:Gem::Dependency
105
- name: execjs
106
- requirement: !ruby/object:Gem::Requirement
107
- requirements:
108
- - - "~>"
109
- - !ruby/object:Gem::Version
110
- version: '1.0'
109
+ requirement: &id006 !ruby/object:Gem::Requirement
110
+ none: false
111
+ requirements:
112
+ - - ~>
113
+ - !ruby/object:Gem::Version
114
+ hash: 15
115
+ segments:
116
+ - 1
117
+ - 0
118
+ version: "1.0"
111
119
  type: :development
120
+ version_requirements: *id006
121
+ - !ruby/object:Gem::Dependency
122
+ name: execjs
112
123
  prerelease: false
113
- version_requirements: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - "~>"
116
- - !ruby/object:Gem::Version
117
- version: '1.0'
118
- - !ruby/object:Gem::Dependency
119
- name: json
120
- requirement: !ruby/object:Gem::Requirement
121
- requirements:
122
- - - ">="
123
- - !ruby/object:Gem::Version
124
- version: '0'
124
+ requirement: &id007 !ruby/object:Gem::Requirement
125
+ none: false
126
+ requirements:
127
+ - - ~>
128
+ - !ruby/object:Gem::Version
129
+ hash: 15
130
+ segments:
131
+ - 1
132
+ - 0
133
+ version: "1.0"
125
134
  type: :development
135
+ version_requirements: *id007
136
+ - !ruby/object:Gem::Dependency
137
+ name: json
126
138
  prerelease: false
127
- version_requirements: !ruby/object:Gem::Requirement
128
- requirements:
129
- - - ">="
130
- - !ruby/object:Gem::Version
131
- version: '0'
132
- - !ruby/object:Gem::Dependency
133
- name: rack-test
134
- requirement: !ruby/object:Gem::Requirement
135
- requirements:
139
+ requirement: &id008 !ruby/object:Gem::Requirement
140
+ none: false
141
+ requirements:
136
142
  - - ">="
137
- - !ruby/object:Gem::Version
138
- version: '0'
143
+ - !ruby/object:Gem::Version
144
+ hash: 3
145
+ segments:
146
+ - 0
147
+ version: "0"
139
148
  type: :development
149
+ version_requirements: *id008
150
+ - !ruby/object:Gem::Dependency
151
+ name: rack-test
140
152
  prerelease: false
141
- version_requirements: !ruby/object:Gem::Requirement
142
- requirements:
143
- - - ">="
144
- - !ruby/object:Gem::Version
145
- version: '0'
146
- - !ruby/object:Gem::Dependency
147
- name: rake
148
- requirement: !ruby/object:Gem::Requirement
149
- requirements:
153
+ requirement: &id009 !ruby/object:Gem::Requirement
154
+ none: false
155
+ requirements:
150
156
  - - ">="
151
- - !ruby/object:Gem::Version
152
- version: '0'
157
+ - !ruby/object:Gem::Version
158
+ hash: 3
159
+ segments:
160
+ - 0
161
+ version: "0"
153
162
  type: :development
163
+ version_requirements: *id009
164
+ - !ruby/object:Gem::Dependency
165
+ name: rake
154
166
  prerelease: false
155
- version_requirements: !ruby/object:Gem::Requirement
156
- requirements:
167
+ requirement: &id010 !ruby/object:Gem::Requirement
168
+ none: false
169
+ requirements:
157
170
  - - ">="
158
- - !ruby/object:Gem::Version
159
- version: '0'
160
- description: Sprockets is a Rack-based asset packaging system that concatenates and
161
- serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.
162
- email:
171
+ - !ruby/object:Gem::Version
172
+ hash: 3
173
+ segments:
174
+ - 0
175
+ version: "0"
176
+ type: :development
177
+ version_requirements: *id010
178
+ description: Sprockets is a Rack-based asset packaging system that concatenates and serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.
179
+ email:
163
180
  - sstephenson@gmail.com
164
181
  - josh@joshpeek.com
165
182
  executables: []
183
+
166
184
  extensions: []
185
+
167
186
  extra_rdoc_files: []
168
- files:
169
- - LICENSE
187
+
188
+ files:
170
189
  - README.md
171
- - lib/sprockets.rb
190
+ - LICENSE
172
191
  - lib/sprockets/asset.rb
173
192
  - lib/sprockets/asset_attributes.rb
174
193
  - lib/sprockets/base.rb
@@ -177,7 +196,6 @@ files:
177
196
  - lib/sprockets/caching.rb
178
197
  - lib/sprockets/charset_normalizer.rb
179
198
  - lib/sprockets/context.rb
180
- - lib/sprockets/digest.rb
181
199
  - lib/sprockets/directive_processor.rb
182
200
  - lib/sprockets/eco_template.rb
183
201
  - lib/sprockets/ejs_template.rb
@@ -187,6 +205,7 @@ files:
187
205
  - lib/sprockets/index.rb
188
206
  - lib/sprockets/jst_processor.rb
189
207
  - lib/sprockets/mime.rb
208
+ - lib/sprockets/processed_asset.rb
190
209
  - lib/sprockets/processing.rb
191
210
  - lib/sprockets/processor.rb
192
211
  - lib/sprockets/safety_colons.rb
@@ -195,27 +214,42 @@ files:
195
214
  - lib/sprockets/trail.rb
196
215
  - lib/sprockets/utils.rb
197
216
  - lib/sprockets/version.rb
217
+ - lib/sprockets.rb
218
+ has_rdoc: true
198
219
  homepage: http://getsprockets.org/
199
220
  licenses: []
200
- metadata: {}
221
+
201
222
  post_install_message:
202
223
  rdoc_options: []
203
- require_paths:
224
+
225
+ require_paths:
204
226
  - lib
205
- required_ruby_version: !ruby/object:Gem::Requirement
206
- requirements:
207
- - - ">="
208
- - !ruby/object:Gem::Version
209
- version: '0'
210
- required_rubygems_version: !ruby/object:Gem::Requirement
211
- requirements:
227
+ required_ruby_version: !ruby/object:Gem::Requirement
228
+ none: false
229
+ requirements:
212
230
  - - ">="
213
- - !ruby/object:Gem::Version
214
- version: '0'
231
+ - !ruby/object:Gem::Version
232
+ hash: 3
233
+ segments:
234
+ - 0
235
+ version: "0"
236
+ required_rubygems_version: !ruby/object:Gem::Requirement
237
+ none: false
238
+ requirements:
239
+ - - ">"
240
+ - !ruby/object:Gem::Version
241
+ hash: 25
242
+ segments:
243
+ - 1
244
+ - 3
245
+ - 1
246
+ version: 1.3.1
215
247
  requirements: []
248
+
216
249
  rubyforge_project: sprockets
217
- rubygems_version: 2.2.2
250
+ rubygems_version: 1.6.2
218
251
  signing_key:
219
- specification_version: 4
252
+ specification_version: 3
220
253
  summary: Rack-based asset packaging system
221
254
  test_files: []
255
+