Created
October 8, 2014 15:31
-
-
Save josqu4red/83825b8840304ca711a1 to your computer and use it in GitHub Desktop.
Revisions
-
josqu4red created this gist
Oct 8, 2014 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,9 @@ OptionParser.new do |o| o.on('-H', '--host hostname') { |hostname| @host = hostname } o.on("-p", "--port port") { |port| @port = port } o.on('-h') { puts o; exit } o.parse! end raise OptionParser::MissingArgument if @host.nil?