Sha256: b8522ebe803aa990014fe9c27846c543edaa312b0b73b3c93d66803f3742c617
Contents?: true
Size: 785 Bytes
Versions: 4
Compression:
Stored size: 785 Bytes
Contents
#!/usr/local/bin/ruby -w # import.rb # # Created by James Edward Gray II on 2005-04-26. # Copyright 2005 Gray Productions. All rights reserved. require "highline" require "forwardable" $terminal = HighLine.new # # <tt>require "highline/import"</tt> adds shorcut methods to Kernel, making # agree(), ask(), and say() globally available. This is handy for quick and # dirty input and output. These methods use the HighLine object in the global # variable <tt>$terminal</tt>, which is initialized to used <tt>$stdin</tt> and # <tt>$stdout</tt> (you are free to change this). Otherwise, these methods are # identical to their HighLine counterparts, see that class for detailed # explinations. # module Kernel extend Forwardable def_delegators :$terminal, :agree, :ask, :say end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
highline-0.3.0 | lib/highline/import.rb |
highline-0.4.0 | lib/highline/import.rb |
highline-0.2.0 | lib/highline/import.rb |
highline-0.5.0 | lib/highline/import.rb |