Skip to content
This repository has been archived by the owner on Sep 18, 2021. It is now read-only.

Commit

Permalink
Merge pull request #23 from twitter/ds-160
Browse files Browse the repository at this point in the history
DS-160 - Accept multiple host and table args
  • Loading branch information
Stu Hood committed Mar 3, 2012
2 parents 7681e01 + badcbf4 commit 3f2add8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/gizzmo.rb
Expand Up @@ -499,7 +499,8 @@ def add_template_opts(subcommand_options, opts)
opts.separator ""
opts.separator "Global options:"
opts.on("-H", "--hosts=HOST[,HOST,...]", "Comma-delimited list of application servers") do |hosts|
global_options.hosts = hosts.split(",").map {|h| h.strip }
global_options.hosts ||= []
global_options.hosts += hosts.split(",").map {|h| h.strip }
end

opts.on("-P", "--port=PORT", "PORT of remote manager service (default 7920)") do |port|
Expand All @@ -511,7 +512,8 @@ def add_template_opts(subcommand_options, opts)
end

opts.on("-T", "--tables=TABLE[,TABLE,...]", "TABLE ids of forwardings to affect") do |tables|
global_options.tables = tables.split(",").map {|t| t.to_i }
global_options.tables ||= []
global_options.tables += tables.split(",").map {|t| t.to_i }
end

opts.on("-F", "--framed", "Use the thrift framed transport") do |framed|
Expand Down

0 comments on commit 3f2add8

Please sign in to comment.