diff options
author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2019-11-13 15:28:12 +0900 |
---|---|---|
committer | aycabta <aycabta@gmail.com> | 2019-11-19 02:39:02 +0900 |
commit | cef9ebfbd3565f9feb25d0140da3176ea26bf4a9 (patch) | |
tree | 41503369774ed5a67585574a583a0e468f79dfe2 /lib | |
parent | 473e314791964019e017410fb761b873d61e591c (diff) |
Suppress `stty` error on Apple Terminal
`stty` called in `Reline::ANSI.deprep` command shows the following
error message on macOS Apple Terminal, with some settings.
```
$ LANG=C irb
irb(main):001:0>
stty: 'standard input': unable to perform all requested operations
stty: 'standard input': unable to perform all requested operations
```
Diffstat (limited to 'lib')
-rw-r--r-- | lib/reline/ansi.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/reline/ansi.rb b/lib/reline/ansi.rb index 35497ab9e2..9b83a00df4 100644 --- a/lib/reline/ansi.rb +++ b/lib/reline/ansi.rb @@ -135,7 +135,7 @@ class Reline::ANSI def self.deprep(otio) int_handle = Signal.trap('INT', 'IGNORE') - `stty #{otio}` + system("stty #{otio}", err: File::NULL) Signal.trap('INT', int_handle) Signal.trap('WINCH', @@old_winch_handler) if @@old_winch_handler end |