sahara 0.0.2 → 0.0.3

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.
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- sahara (0.0.2)
4
+ sahara (0.0.3)
5
5
  popen4 (~> 0.1.2)
6
6
  thor (~> 0.14.6)
7
7
  vagrant (~> 0.7.0)
@@ -155,14 +155,27 @@ module Sahara
155
155
  end
156
156
 
157
157
  def self.on_selected_vms(selection,&block)
158
+
158
159
  if selection.nil?
159
160
  #puts "no selection was done"
160
161
  @vagrant_env.vms.each do |name,vm|
161
162
  #puts "Processing #{name}"
162
- yield name
163
+ if @vagrant_env.multivm? && name.to_s!="default"
164
+ if is_vm_created?(name)
165
+ yield name
166
+ else
167
+ puts "[#{name}] - machine needs to be upped first"
168
+ end
169
+ else
170
+ #skipping default
171
+ end
163
172
  end
164
173
  else
165
- yield selection
174
+ if is_vm_created?(selection)
175
+ yield selection
176
+ else
177
+ puts "[#{selection}] - machine needs to be upped first"
178
+ end
166
179
  end
167
180
  end
168
181
  end
@@ -1,3 +1,3 @@
1
1
  module Sahara
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sahara
3
3
  version: !ruby/object:Gem::Version
4
- hash: 27
4
+ hash: 25
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 2
10
- version: 0.0.2
9
+ - 3
10
+ version: 0.0.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Patrick Debois