class Test
options = Trollop::options do
opt :mode, "Select script mode", :default => 0
opt :net, "Internal IP range", :type => :string
end
@options = options
def test
pp @options
end
end
Why does @options return nil when I call test()?
I've also tried setting @options to instance when Trollop is first called. I need to be able to pass the options hash returned from Trollop into different methods in the class.