From: elijah Date: Wed, 25 Jun 2014 19:48:04 +0000 (-0700) Subject: allow file(x, :missing => '') macro to report the path of x in the missing text. X-Git-Url: https://gitweb.fluxo.info/?a=commitdiff_plain;ds=inline;p=leap%2Fleap_cli.git allow file(x, :missing => '') macro to report the path of x in the missing text. --- diff --git a/lib/leap_cli/config/object.rb b/lib/leap_cli/config/object.rb index 3375c6a..2392d1c 100644 --- a/lib/leap_cli/config/object.rb +++ b/lib/leap_cli/config/object.rb @@ -261,7 +261,7 @@ module LeapCli rescue FileMissing => exc Util::bail! do if exc.options[:missing] - Util::log :missing, exc.options[:missing].gsub('$node', self.name) + Util::log :missing, exc.options[:missing].gsub('$node', self.name).gsub('$file', exc.path) else Util::log :error, "while evaluating node '#{self.name}'" Util::log "offending key: #{key}", :indent => 1