HBASE-2710. Shell should have default terminal width when detection fails
git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@953529 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
bdcc7f126a
commit
296b055f97
|
@ -381,6 +381,8 @@ Release 0.21.0 - Unreleased
|
|||
HBASE-2684 TestMasterWrongRS flaky in trunk
|
||||
HBASE-2691 LeaseStillHeldException totally ignored by RS, wrongly named
|
||||
HBASE-2703 ui not working in distributed context
|
||||
HBASE-2710 Shell should use default terminal width when autodetection fails
|
||||
(Kannan Muthukkaruppan via Todd Lipcon)
|
||||
|
||||
IMPROVEMENTS
|
||||
HBASE-1760 Cleanup TODOs in HTable
|
||||
|
|
|
@ -31,6 +31,12 @@ module Shell
|
|||
|
||||
def refresh_width()
|
||||
@max_width = Java::jline.Terminal.getTerminal().getTerminalWidth()
|
||||
|
||||
# the above doesn't work in some terminals
|
||||
# (such as shell running within emacs)
|
||||
if @max_width == 0
|
||||
@max_width = 100
|
||||
end
|
||||
end
|
||||
|
||||
# Takes an output stream and a print width.
|
||||
|
|
Loading…
Reference in New Issue