classy_assets 0.0.5 → 0.1.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 49b66515e79f2be8ddc847a703133e48d8bc373e
4
- data.tar.gz: e9e809378962539e2a5f5203294dcb78a405fc70
3
+ metadata.gz: 402eeab6d0e3be6d72373ace2b0ff08917ce6e86
4
+ data.tar.gz: fee275b0661ec4cea396e4dda52ce3fcba03ddb4
5
5
  SHA512:
6
- metadata.gz: 55986dd94d05a3ebd885aede3398b4079f9c791329178491446cff9c5e3aba2de6357a68b3c08010ad2f565f55226b5d6f217cb8260ff53220bb11192601ab44
7
- data.tar.gz: 3cbb973af36883f652756efb1dd09e66c6fc17a8c23b759492d07a9889904ece13aeef9d594ce71fcef27a420d54f9fc3ce00643e3a0a231650692e707c4fd02
6
+ metadata.gz: 27ae5211d321c8a04fed56bfd7312507969496a451a012d328f794ada6b33fee97d96106029772ebe4eb4a68f4bdea6a1a7722b0b2a3fd6901c347eff014496a
7
+ data.tar.gz: 507872447fd978ec3b76fd3158ba980e253e2febf393a0b007fcbb38aeadb280c16f8b79f71bbfbfe7150047fc23f4221c8fcd6e797a1f97fb86bf13901c8623
@@ -1,3 +1,3 @@
1
1
  module ClassyAssets
2
- VERSION = "0.0.5"
2
+ VERSION = "0.1.0"
3
3
  end
data/lib/classy_assets.rb CHANGED
@@ -15,12 +15,12 @@ module ClassyAssets
15
15
  @asset_digest = digest
16
16
  end
17
17
 
18
- def self.asset_dirs
19
- @asset_dirs ||= %w(fonts images javascripts stylesheets)
18
+ def self.asset_paths
19
+ @asset_paths ||= build_asset_path(%w(fonts images javascripts stylesheets))
20
20
  end
21
21
 
22
- def self.asset_dirs=(dirs)
23
- @asset_dirs = dirs
22
+ def self.asset_paths=(paths)
23
+ @asset_paths = paths.to_a
24
24
  end
25
25
 
26
26
  def self.asset_host
@@ -79,12 +79,16 @@ module ClassyAssets
79
79
  @root_path = path
80
80
  end
81
81
 
82
+ def self.build_asset_path(dir_names)
83
+ dir_names.map! do |dir_name|
84
+ File.join(root_path, asset_prefix, dir_name)
85
+ end
86
+ dir_names
87
+ end
88
+
82
89
  def self.sprockets
83
90
  @sprockets ||= Sprockets::Environment.new(root_path)
84
- asset_dirs.each do |asset_dir|
85
- _path = File.join(root_path, asset_prefix, asset_dir)
86
- @sprockets.append_path _path
87
- end
91
+ asset_paths.each { |asset_path| @sprockets.append_path asset_path }
88
92
  @sprockets
89
93
  end
90
94
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: classy_assets
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - StyleSeek Engineering
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-07-18 00:00:00.000000000 Z
11
+ date: 2013-07-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sinatra