diff options
author | Nobuyoshi Nakada <[email protected]> | 2020-05-20 10:52:32 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <[email protected]> | 2020-05-20 10:52:32 +0900 |
commit | 2480ef904c66812cf366e5d9bc8a9c3c20bbf271 (patch) | |
tree | edb86aa3ef40a8d3e8a5c4e9db32949e8f0b1467 | |
parent | 67d259c5dccd31fe49d417fec169977712ffdf10 (diff) |
pure_parser.rb: get rid of an error at localed messages
-rwxr-xr-x | tool/pure_parser.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tool/pure_parser.rb b/tool/pure_parser.rb index d07df681be..21c87cc5d6 100755 --- a/tool/pure_parser.rb +++ b/tool/pure_parser.rb @@ -1,11 +1,14 @@ #!/usr/bin/ruby -pi.bak BEGIN { + # pathological setting + ENV['LANG'] = ENV['LC_MESSAGES'] = ENV['LC_ALL'] = 'C' + require_relative 'lib/colorize' colorize = Colorize.new file = ARGV.shift begin - version = IO.popen(ARGV+%w[--version], &:read) + version = IO.popen(ARGV+%w[--version], "rb", &:read) rescue Errno::ENOENT abort "Failed to run `#{colorize.fail ARGV.join(' ')}'; You may have to install it." end |