thematic 0.0.9 → 0.0.10

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: cdd39110079ffa3ebcc24f6a1fc81874aafb4ab0
4
- data.tar.gz: 907ba0fbe0d6f8b25d9b44f531c61f8e6de5b8e2
3
+ metadata.gz: e7c488db698bbd019711bbb645d470f6895e6941
4
+ data.tar.gz: 4ce4bcdccf68afbffe379048308a561cfe68de41
5
5
  SHA512:
6
- metadata.gz: 0031c7a06aff545a65957fb97c32da330e3cc982d99e91c7b57553bdba6158c7cf99948842e25a4d79795509bf1c2fad84dae6a351829b172d35029f6f70ba8a
7
- data.tar.gz: 817472e284edd1eef96647a84398c3264bc5a09832f37f04af7294170efcf25087154231e37cd54f4c1689a2ab76e25bd06d0880fe9701284db2aa504c629195
6
+ metadata.gz: 5fbe3f5e79cbd253179f69d69c40df2e4db54781ae80878301981c97814d0c78d6c8c69e995a88208cb1ffcc14e6cab1cbea137c0216e2d06595bd1495eb4cd5
7
+ data.tar.gz: 6f2580c94260a484b895863061d40e28e4c401dd6fc0c10f3996222707d643d413eaa85812af11dd577fb36d1cb056ee8d971c357d2282b4047bd2f141af5229
@@ -23,8 +23,11 @@ namespace :thematic do
23
23
  if line =~/^*= require_tree ./ #we want to insert new require statements above this line
24
24
  files_to_copy = Dir[ File.join(copy_from_path, '**', '*') ]
25
25
 
26
+ #filter out minified versions of libraries that also have a non-minified version
27
+ files_to_copy.reject! { |filename| filename.index(".min") && files_to_copy.include?(filename.gsub(".min", "")) }
28
+
26
29
  files_to_copy.each do |filepath|
27
- unless File.directory?(filepath) || filepath.end_with?("min.css") || filepath.end_with?(".map")
30
+ unless File.directory?(filepath) || filepath.end_with?(".map")
28
31
  filename = filepath.split("/").last
29
32
  copy(filepath, "vendor/assets/stylesheets/#{theme_subfolder}/")
30
33
  tempfile << " *= require #{theme_subfolder}/#{filename.gsub('.css', '')}\n"
@@ -54,8 +57,11 @@ namespace :thematic do
54
57
  if line =~/^\/\/= require_tree ./ #we want to insert new require statements above
55
58
  files_to_copy = Dir[ File.join(copy_from_path, '**', '*') ]
56
59
 
60
+ #filter out minified versions of libraries that also have a non-minified version
61
+ files_to_copy.reject! { |filename| filename.index(".min") && files_to_copy.include?(filename.gsub(".min", "")) }
62
+
57
63
  files_to_copy.each do |filepath|
58
- unless File.directory?(filepath) || filepath.end_with?("min.js") || filepath.end_with?(".map")
64
+ unless File.directory?(filepath) || filepath.end_with?(".map")
59
65
  filename = filepath.split("/").last
60
66
  copy(filepath, "vendor/assets/javascripts/#{theme_subfolder}/")
61
67
  tempfile << "//= require #{theme_subfolder}/#{filename.gsub('.js', '')}\n"
@@ -127,8 +133,7 @@ namespace :thematic do
127
133
  f.each do |line|
128
134
  if line =~/background.*url/
129
135
  image_filename = /\(.*\)/.match(line)[0].delete('(').delete(')').split("/").last.delete('"')
130
- new_snippet = "(\"<%= asset_path('#{image_filename}') %>\")"
131
- # modified_line = line.gsub("../", "").gsub("img", "<%= asset_path('#{theme_subfolder}").gsub("\")", "')%>\")")
136
+ new_snippet = "(\"<%= asset_path('#{theme_subfolder}/#{image_filename}') %>\")"
132
137
  modified_line = line.gsub(/\(.*\)/, new_snippet)
133
138
  tempfile << modified_line
134
139
  else
@@ -1,3 +1,3 @@
1
1
  module Thematic
2
- VERSION = "0.0.9"
2
+ VERSION = "0.0.10"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: thematic
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.9
4
+ version: 0.0.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jay Wengrow
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-04-28 00:00:00.000000000 Z
11
+ date: 2015-04-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler