summaryrefslogtreecommitdiff
path: root/baserockimport/exts/rubygems.to_lorry
diff options
context:
space:
mode:
authorRichard Ipsum <richard.ipsum@codethink.co.uk>2015-01-14 16:06:53 +0000
committerRichard Ipsum <richard.ipsum@codethink.co.uk>2015-01-14 16:06:53 +0000
commit8f32749511f4cab0ac1c6d74025fc1b21578996c (patch)
treef6cc78d83f1a7b5c330b8a54732c2ee84191f34a /baserockimport/exts/rubygems.to_lorry
parentb092a66c21cb977a872d2b45d8edec31d96eeb28 (diff)
parent8d0448d044f20a148f98700a691a83c95308a8e8 (diff)
downloadimport-8f32749511f4cab0ac1c6d74025fc1b21578996c.tar.gz
Merge branch 'baserock/richardipsum/fix-lorry-bug-3'
Reviewed by: Sam Thursfield <sam.thursfield@codethink.co.uk>
Diffstat (limited to 'baserockimport/exts/rubygems.to_lorry')
-rwxr-xr-xbaserockimport/exts/rubygems.to_lorry5
1 files changed, 3 insertions, 2 deletions
diff --git a/baserockimport/exts/rubygems.to_lorry b/baserockimport/exts/rubygems.to_lorry
index d5f1efa..0413204 100755
--- a/baserockimport/exts/rubygems.to_lorry
+++ b/baserockimport/exts/rubygems.to_lorry
@@ -76,9 +76,10 @@ class RubyGemLorryGenerator(ImportExtension):
"Loaded %i known source URIs from local metadata.", len(self.known_source_uris))
def process_args(self, args):
- if len(args) != 1:
+ if len(args) not in [1, 2]:
raise ImportException(
- 'Please call me with the name of a RubyGem as an argument.')
+ 'Please call me with the name of a RubyGem as an argument'
+ ' and optionally its version number (format: NAME [VERSION])')
gem_name = args[0]