Sha256: 915b539a53a6f3011da861f54ddd0387a049a57707164cf082b5ce1e10b4adf2

Contents?: true

Size: 361 Bytes

Versions: 7

Compression:

Stored size: 361 Bytes

Contents

require 'rib'
require 'readline'

module Rib::Readline
  extend Rib::Plugin
  Shell.use(self)

  # --------------- Rib API ---------------

  def before_loop
    return super if Readline.disabled?
    config[:history] = ::Readline::HISTORY
    super
  end

  def get_input
    return super if Readline.disabled?
    ::Readline.readline(prompt, true)
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
rib-1.1.6 lib/rib/core/readline.rb
rib-1.1.5 lib/rib/core/readline.rb
rib-1.1.4 lib/rib/core/readline.rb
rib-1.1.3 lib/rib/core/readline.rb
rib-1.1.2 lib/rib/core/readline.rb
rib-1.1.1 lib/rib/core/readline.rb
rib-1.1.0 lib/rib/core/readline.rb