black_operation 0.1.1 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 10d0e2a42970382b2030a1fa68b802e53479a73f
4
- data.tar.gz: b33b3be31ca231cd922fa33728e6c7bb5208c1ff
3
+ metadata.gz: 4b6fc0115670f6b5c7f21db01f7e19e67afe35d4
4
+ data.tar.gz: f2d1221515d933cdc79f24b784ac0cf8471e61bc
5
5
  SHA512:
6
- metadata.gz: 39b9944a98d3ae7821b40532b73040e27824b78a077da4196c0504a95160da228cf75f19e31b50c62a1af2d239b707fdc664c08717699f49de86cdccd24763cf
7
- data.tar.gz: f4222edb583cf0940e7f24b67278428b984576322186f3b138d1d08d5e43847078d3b127ca42c27c1ed659521164773b3a46a79dde32841a01fbf1166e170696
6
+ metadata.gz: 71d63cc394b187657303b4708d627d052eccdae01f3cf0b21bfea93feb68a4c506cd370cd526a3d476230580399bda3312e4245c7eceb6a74cb9f68e27fdc295
7
+ data.tar.gz: fb44b3558118cabbac49a71757da7d3e2ef8166707b0a4b150f28ebc5d0bee4b9c0df08b73e31f3a6eb95af42173b19532a21f363d02e93ed8cf6e20e150d744
@@ -1,3 +1,3 @@
1
1
  module BlackOperation
2
- VERSION = "0.1.1"
2
+ VERSION = "0.2.1"
3
3
  end
data/lib/tasks/install.rb CHANGED
@@ -11,7 +11,7 @@ namespace :black_operation do
11
11
 
12
12
  desc "Runs \"rails runner\" on all scripts in the install directory after migrations skips schema load"
13
13
  task :update_install do
14
- #`bundle exec rake db:migrate`
14
+ `bundle exec rake db:migrate`
15
15
  run_scripts
16
16
  end
17
17
 
@@ -22,8 +22,30 @@ namespace :black_operation do
22
22
  f = File.new("./public/javascripts/#{folder}/#{script}","w+")
23
23
  f.write(compiled_contents);
24
24
  f.close
25
- puts "Done!"
26
25
  end
27
26
  end
27
+ puts "Done!"
28
+ end
29
+
30
+ desc "Fix JQuery-UI images in production assuming it's images are found in app/assets/images/images (ie changes all relative images/ paths to absolute /images/ path"
31
+ task :fix_jquery_ui do
32
+ #find the compiled css file (cover the .gz too)
33
+ prefix = Rails.configuration.assets.prefix
34
+ path = "public"+prefix+"/**/*"
35
+ Dir.glob(path) do |file|
36
+ if File.extname(file.to_s) == ".css" || File.extname(file.to_s.chomp(File.extname(file.to_s))) == ".css"
37
+ puts "Full File: #{file.to_s}"
38
+ file_handle = File.open("./"+file.to_s,"rb")
39
+ file_contents = file_handle.read
40
+ file_contents.gsub!(/images\//,"/images/")
41
+ #fix double forward-slash
42
+ file_contents.gsub!(/\/\/images\//,"/images/");
43
+ file_handle.close
44
+ file_handle = File.new(file.to_s,"wb")
45
+ file_handle.write(file_contents)
46
+ file_handle.close
47
+ end
48
+ end
49
+ puts "Done!"
28
50
  end
29
51
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: black_operation
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Travis Pessetto
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-06-09 00:00:00.000000000 Z
11
+ date: 2014-06-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler