ruby--ruby/sample/getoptlong/aliases.rb

9 lines
176 B
Ruby
Raw Normal View History

require 'getoptlong'
options = GetoptLong.new(
['--xxx', '-x', '--aaa', '-a', '-p', GetoptLong::NO_ARGUMENT]
)
options.each do |option, argument|
p [option, argument]
end