aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/leap_cli/commands/inspect.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/leap_cli/commands/inspect.rb b/lib/leap_cli/commands/inspect.rb
index 025d244..1856ad6 100644
--- a/lib/leap_cli/commands/inspect.rb
+++ b/lib/leap_cli/commands/inspect.rb
@@ -1,9 +1,11 @@
module LeapCli; module Commands
desc 'Prints information about a file or node.'
+ arg_name '<file-or-node>', :optional => false
command :inspect do |c|
c.action do |global_options,options,args|
object = args.first
+ assert! object, 'A file path or node name is required'
method = inspection_method(object)
if method && defined?(method)
self.send(method, object, options)