summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Ipsum <richard.ipsum@codethink.co.uk>2015-01-09 17:30:51 +0000
committerRichard Ipsum <richard.ipsum@codethink.co.uk>2015-01-13 15:40:03 +0000
commitc7faa275594bfe3ffd84be0622fb856753137cfe (patch)
tree05cd8ad32ab4196317c597418d2568443827b4f9
parentdfd8ab146d790ad582b3da8d417735d5134903eb (diff)
downloadimport-c7faa275594bfe3ffd84be0622fb856753137cfe.tar.gz
Make rubygems lorry ext work with new interface
-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]