mofa 0.3.25 → 0.3.26

Sign up to get free protection for your applications and to get access to all the features.
@@ -40,9 +40,7 @@ class ReleasedCookbook < Cookbook
40
40
  end
41
41
 
42
42
  def package
43
-
44
43
  tar_verbose = (Mofa::CLI::option_debug) ? 'v' : ''
45
-
46
44
  mkdir_p @pkg_dir
47
45
  say "Downloading released cookbook from: #{cookbooks_url} to #{pkg_dir}/#{pkg_name}..."
48
46
  File.open("#{pkg_dir}/#{pkg_name}", "wb") do |saved_file|
@@ -53,6 +51,17 @@ class ReleasedCookbook < Cookbook
53
51
  end
54
52
  mkdir_p "#{pkg_dir}/tmp"
55
53
  run "tar x#{tar_verbose}fz #{pkg_dir}/#{pkg_name} -C #{pkg_dir}/tmp/"
54
+
55
+ COOKBOOK_IGNORE.each do |remove_this|
56
+ if File.exists?("#{pkg_dir}/tmp/cookbooks/#{name}/#{remove_this}")
57
+ run "rm -rf #{pkg_dir}/tmp/cookbooks/#{name}/#{remove_this}"
58
+ end
59
+ end
60
+
61
+ run "cd #{pkg_dir}/tmp/;tar c#{tar_verbose}fz #{pkg_dir}/#{pkg_name}.new ."
62
+ run "rm #{pkg_dir}/#{pkg_name}"
63
+ run "mv #{pkg_dir}/#{pkg_name}.new #{pkg_dir}/#{pkg_name}"
64
+ run "rm -rf #{pkg_dir}/tmp/"
56
65
  end
57
66
 
58
67
  def load_mofa_yml
@@ -64,9 +73,8 @@ class ReleasedCookbook < Cookbook
64
73
  end
65
74
 
66
75
  # ------------- /Interface Methods
67
-
68
76
  def source_dir
69
- pkg_dir
77
+ "#{pkg_dir}/tmp/cookbooks/#{name}"
70
78
  end
71
79
 
72
80
  def cleanup!
data/lib/mofa/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Mofa
2
- VERSION = "0.3.25"
2
+ VERSION = "0.3.26"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mofa
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.25
4
+ version: 0.3.26
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: