incubator-deltacloud-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lut...@redhat.com
Subject [PATCH 2/2] * client/bin/deltacloudc: print error if ID for show operation is missing
Date Fri, 22 Oct 2010 22:52:57 GMT
From: David Lutterkort <lutter@redhat.com>

---
 client/bin/deltacloudc |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/client/bin/deltacloudc b/client/bin/deltacloudc
index 5153e35..9408f90 100755
--- a/client/bin/deltacloudc
+++ b/client/bin/deltacloudc
@@ -124,6 +124,7 @@ if options[:collection] and options[:operation]
   # If collection is set and requested operation is 'show' just 'singularize'
   # collection name and print item with specified id (-i parameter)
   if options[:operation].eql?('show')
+    invalid_usage("Missing ID, must be provided with --id") unless options[:id]
     puts format(client.send(options[:collection].gsub(/s$/, ''), options[:id]))
     exit(0)
   end
-- 
1.7.2.3


Mime
View raw message