hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bus...@apache.org
Subject [23/26] hbase git commit: HBASE-18393 Fix shell noninteractive launch
Date Thu, 20 Jul 2017 05:43:00 GMT
HBASE-18393 Fix shell noninteractive launch

Signed-off-by: Sean Busbey <busbey@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/775179bc
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/775179bc
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/775179bc

Branch: refs/heads/HBASE-18147
Commit: 775179bc4a725ef7f252bcec4c37882db17dc857
Parents: 3574757
Author: Mike Drob <mdrob@apache.org>
Authored: Wed Jul 19 12:17:02 2017 -0500
Committer: Sean Busbey <busbey@apache.org>
Committed: Wed Jul 19 13:54:55 2017 -0500

----------------------------------------------------------------------
 bin/hirb.rb | 9 +++++++++
 1 file changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/775179bc/bin/hirb.rb
----------------------------------------------------------------------
diff --git a/bin/hirb.rb b/bin/hirb.rb
index d0295d6..841ab54 100644
--- a/bin/hirb.rb
+++ b/bin/hirb.rb
@@ -215,6 +215,15 @@ else
     require "irb/workspace"
     workspace = IRB::WorkSpace.new(binding())
     scanner = RubyLex.new
+
+    # RubyLex claims to take an IO but really wants an InputMethod
+    module IOExtensions
+      def encoding
+        external_encoding
+      end
+    end
+    IO.include IOExtensions
+
     scanner.set_input(STDIN)
     scanner.each_top_level_statement do |statement, linenum|
        puts(workspace.evaluate(nil, statement, 'stdin', linenum))


Mime
View raw message