lib/jets/command/base.rb in jets-5.0.0 vs lib/jets/command/base.rb in jets-5.0.1
- old
+ new
@@ -97,9 +97,14 @@
command, args = "help", []
self.full_namespace = full_namespace # store for help. clean:log => log
end
dispatch(command, args.dup, nil, config)
+ rescue Thor::InvocationError => e
+ puts e.message.color(:red) # message already has ERROR prefix
+ self.full_namespace = full_namespace # store for help. clean:log => log
+ dispatch("help", [], nil, config)
+ exit 1
end
def printing_commands
namespaced_commands
end