Make stdout and stderr utf8
It seems stdout and stderr are not in utf8, so commands such as rbm/rbm showconf browser build --target torbrowser-windows-x86_64 --target nightly --target testbuild
in tor-browser-build will not show correctly
the character ©
(used in projects/browser/windows-installer.nsi
)
correctly when the terminal is in utf8.
/cc @pierov
- Show closed items
Activity
-
Newest first Oldest first
-
Show all activity Show comments only Show history only
This seems to fix the issue:
diff --git a/rbm b/rbm index c99de28..a2dd36f 100755 --- a/rbm +++ b/rbm @@ -90,6 +90,8 @@ sub set_options { sub show_conf { shift; my $args = set_options(@_); + binmode(STDOUT, ":utf8"); + binmode(STDERR, ":utf8"); if (@$args == 0) { print YAML::XS::Dump($RBM::config); return;
Collapse replies Adding the line
use open OUT => ':locale';
seems to fix the issue too, and is setting output encoding based on locale environment variables, according to https://perldoc.perl.org/open.diff --git a/rbm b/rbm index c99de28..de6e083 100755 --- a/rbm +++ b/rbm @@ -1,6 +1,7 @@ #!/usr/bin/perl -w use strict; +use open OUT => ':locale'; use File::Basename; use lib dirname($0) . '/lib'; use RBM;
- boklm mentioned in merge request !56 (merged)
mentioned in merge request !56 (merged)
- morgan closed with merge request !56 (merged)
closed with merge request !56 (merged)
- Pier Angelo Vendrame mentioned in merge request tor-browser-build!904 (merged)
mentioned in merge request tor-browser-build!904 (merged)
- boklm marked this issue as related to tor-browser-build#41074 (closed)
marked this issue as related to tor-browser-build#41074 (closed)
- boklm marked this issue as related to tor-browser-build#41075 (closed)
marked this issue as related to tor-browser-build#41075 (closed)
- boklm marked this issue as related to tor-browser-build#41061 (closed)
marked this issue as related to tor-browser-build#41061 (closed)
- boklm marked this issue as related to tor-browser-build#41062 (closed)
marked this issue as related to tor-browser-build#41062 (closed)
- boklm added Build System label
added Build System label
- boklm mentioned in merge request tor-browser-build!905 (merged)
mentioned in merge request tor-browser-build!905 (merged)
- boklm mentioned in commit tor-browser-build@cfa73f9c
mentioned in commit tor-browser-build@cfa73f9c
- boklm mentioned in commit tor-browser-build@125e1e35
mentioned in commit tor-browser-build@125e1e35