[Rd] localeToCharset()

Rasmus Liland jr@| @end|ng |rom po@teo@no
Mon Jan 31 11:35:06 CET 2022


Dear Andreas,

I think your R session is able to use 
correct unicode from your Fedora docker 
container, because I get the same output 
from `localeToCharset()` on my similarly 
configured ArchLinux system.

I found some notes on setting locale in 
Fedora [1]

On ArchLinux, I set my locale globally 
in /etc/locale.conf, since a long time 
ago

	LANG=en_GB.UTF-8
	LC_CTYPE="en_GB.UTF-8"
	LC_NUMERIC="en_GB.UTF-8"
	LC_TIME="en_DK.UTF-8"
	LC_COLLATE="en_GB.UTF-8"
	LC_MONETARY="nb_NO.UTF-8"
	LC_PAPER="nb_NO.UTF-8"
	LC_NAME="nb_NO.UTF-8"
	LC_ADDRESS="nb_NO.UTF-8"
	LC_TELEPHONE="nb_NO.UTF-8"
	LC_MEASUREMENT="nb_NO.UTF-8"
	LC_INDENTIFICATION="nb_NO.UTF-8"

On FreeBSD, it is customary to set the 
locale locally in your ~/.login_conf

	me:\
		:charset=UTF-8:\
		:lang=en_GB.UTF-8:\
		:setenv=LC_COLLATE=C:

OpenBSD has UTF-8 enabled for everything 
all of the time (I'm thinking), coming 
from a state not long ago where it was 
largely unavailable ...

Best,
Rasmus

[1] https://docs.fedoraproject.org/en-US/Fedora/26/html/System_Administrators_Guide/ch-System_Locale_and_Keyboard_Configuration.html



More information about the R-devel mailing list