aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorelijah <elijah@riseup.net>2014-06-25 12:48:04 -0700
committerelijah <elijah@riseup.net>2014-06-25 14:20:50 -0700
commit56f58507bd5c0d25108443d083b26397ad30dcc3 (patch)
tree1fb7193562853e4d1f48763b22a8ed6d8137ea18
parente60a5e591f1c2aa0a2f41e97aa6fbf61b66db95c (diff)
downloadleap_cli-56f58507bd5c0d25108443d083b26397ad30dcc3.tar.gz
leap_cli-56f58507bd5c0d25108443d083b26397ad30dcc3.tar.bz2
allow file(x, :missing => '') macro to report the path of x in the missing text.
-rw-r--r--lib/leap_cli/config/object.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/leap_cli/config/object.rb b/lib/leap_cli/config/object.rb
index d609256..ef66757 100644
--- a/lib/leap_cli/config/object.rb
+++ b/lib/leap_cli/config/object.rb
@@ -257,7 +257,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