mandy 0.4.4 → 0.4.5
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/mandy.rb +4 -1
- metadata +1 -1
data/lib/mandy.rb
CHANGED
@@ -57,7 +57,10 @@ at_exit do
|
|
57
57
|
input = Mandy.local_input || ENV['MANDY_INPUT']
|
58
58
|
unless input
|
59
59
|
print "Input file: "
|
60
|
-
input = gets.chomp
|
60
|
+
input = (gets || '').chomp
|
61
|
+
end
|
62
|
+
if input.nil? or input.size==0 or !File.exists?(input)
|
63
|
+
raise "Input file #{input.nil? or input.size==0 ? 'was not provided' : "'#{input}' does not exist"}! Try specifying 'Mandy.local_input=' or if Mandy has launched by mistake then set 'Mandy.autorun = false' to avoid this check."
|
61
64
|
end
|
62
65
|
file = caller
|
63
66
|
output_folder = FileUtils.mkdir_p("/tmp/mandy-local")
|