Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add option to specify host on cmd line. Helpful if you manage several…

… geminaboxes.

Signed-off-by: Tom Lea <commit@tomlea.co.uk>
  • Loading branch information...
commit 3b68238eaf848675113ae0139d738008de1eb698 1 parent 01abc65
Martin Moen Wulffeld wulffeld authored cwninja committed
Showing with 6 additions and 2 deletions.
  1. +1 −1  geminabox.gemspec
  2. +5 −1 lib/rubygems/commands/inabox_command.rb
2  geminabox.gemspec
View
@@ -1,6 +1,6 @@
Gem::Specification.new do |s|
s.name = 'geminabox'
- s.version = '0.2.9'
+ s.version = '0.2.10'
s.summary = 'Really simple rubygem hosting'
s.description = 'A sinatra based gem hosting app, with client side gem push style functionality.'
s.author = 'Tom Lea'
6 lib/rubygems/commands/inabox_command.rb
View
@@ -19,6 +19,10 @@ def initialize
add_option('-c', '--configure', "Configure GemInABox") do |value, options|
options[:configure] = true
end
+
+ add_option('-g', '--host HOST', "Host to upload to.") do |value, options|
+ options[:host] = value
+ end
end
def execute
@@ -88,7 +92,7 @@ def configure
end
def geminabox_host
- geminabox_host ||= Gem.configuration.load_file(config_path)[:host]
+ @geminabox_host ||= options[:host] || Gem.configuration.load_file(config_path)[:host]
end
def geminabox_host=(host)
Please sign in to comment.
Something went wrong with that request. Please try again.