lib/kameleon/engine.rb in kameleon-builder-2.6.2 vs lib/kameleon/engine.rb in kameleon-builder-2.6.3

- old
+ new

@@ -1,9 +1,10 @@ require 'kameleon/recipe' require 'kameleon/context' require 'kameleon/persistent_cache' -# require 'pry' + + module Kameleon class Engine attr_accessor :recipe attr_accessor :cwd @@ -214,9 +215,12 @@ def safe_exec_cmd(cmd, kwargs = {}) finished = false begin exec_cmd(cmd, kwargs) + finished = true + rescue ContextClosed => e + Kameleon.ui.warn("#{e.message}") finished = true rescue SystemExit, Interrupt, ExecError reload_contexts finished = rescue_exec_error(cmd) end until finished