Check INPUTRC env in Reline::Config

This commit is contained in:
aycabta 2019-05-12 23:20:51 +09:00
parent aaaede8bcf
commit 11476e9902
2 changed files with 2 additions and 1 deletions

View File

@ -31,7 +31,6 @@ module Reline
end
@@config = Reline::Config.new
@@config.read
@@line_editor = Reline::LineEditor.new(@@config)
@@ambiguous_width = nil
@ -134,6 +133,7 @@ module Reline
def inner_readline(prompt, add_hist, multiline, &confirm_multiline_termination)
otio = prep
@@config.read
may_req_ambiguous_char_width
if multiline

View File

@ -37,6 +37,7 @@ class Reline::Config
end
def read(file = DEFAULT_PATH)
file = ENV['INPUTRC'] if ENV['INPUTRC']
begin
if file.respond_to?(:readlines)
lines = file.readlines