lib/playmo/recipe/dsl.rb in playmo-0.1.7 vs lib/playmo/recipe/dsl.rb in playmo-0.1.8
- old
+ new
@@ -36,10 +36,20 @@
def after(after)
@after = after
after_recipe = Playmo::Cookbook.instance.find_recipe(@after)
if after_recipe.nil? && @after.present?
- require "#{Playmo::ROOT}/recipes/#{@after}_recipe.rb"
+ #$:.each {|path| puts "!#{path}!"}
+ #raise "FUCK!!!"
+
+ #require "#{Playmo::ROOT}/recipes/#{@after}_recipe.rb"
+ begin
+ require "#{@after}_recipe.rb"
+ rescue LoadError => e
+ puts "Cannot load recipe '#{@after}_recipe.rb'!"
+ puts "LOAD PATHS:\n#{$:.join("\n")}"
+ exit!
+ end
end
if after_recipe.nil?
Playmo::Cookbook.instance.use(self)
else
\ No newline at end of file