Tiny Core Extensions > TCE Bugs

getlocale.sh fails silently in urxvt (rxvt.tcz) terminal

(1/2) > >>

GNUser:
Running  getlocale.sh  in an urxvt terminal fails silently (nothing happens, no errors are shown):

--- Code: ---$ sudo getlocale.sh
$
--- End code ---

A little investigating reveals the problem:

--- Code: ---$ sudo dialog --file /tmp/tmp.0vWiFQ
Error opening terminal: rxvt-unicode-256color.
$ echo $TERM
rxvt-unicode-256color
--- End code ---

The fix:

--- Code: ---$ export TERM=rxvt # or export TERM=xterm
$ sudo getlocale.sh # now it works :)
--- End code ---

Maybe export TERM=rxvt or export TERM=xterm should be at the top of the getlocale.sh script (which is part of the  getlocale.tcz  extension)

GNUser:
P.S. The  rxvt-unicode-256color  value of the TERM variable has causes problems for me before (some other application or script--I can't remember exactly what it was--wouldn't work until I did export TERM=rxvt).

@andyj - is there a particular reason why the urxvt terminal sets  TERM  to  rxvt-unicode-256color  ? If possible, setting the value to simply  rxvt  would avoid this and similar problems.

jazzbiker:
Hi, GNUser and all Core people!

You can change rxvt TERM variable using .Xdefaults. Add the string

--- Code: ---urxvt*termName: rxvt

--- End code ---
and in new urxvt window You'll got:

--- Code: ---tc@box:~$ echo $TERM
rxvt

--- End code ---

Side effect of this action is, that, for example, mc will not be able to use 256-color themes, .

andyj:
Urxvt sets TERM by default to rxvt-unicode-256color in the source. There isn't anything in the extension which changes this behavior. I used getlocale.sh with rxvt and it worked for me, I can not reproduce the problem. You can also change it on the command line with the -tn option.

GNUser:

--- Quote from: jazzbiker on August 03, 2020, 03:50:21 PM ---You can change rxvt TERM variable using .Xdefaults.

--- End quote ---
Thank you, jazzbiker. I learned something new. I'll do that--I use rxvt for the unicode (not for the colors), so no love lost.


--- Quote from: andyj on August 03, 2020, 04:17:55 PM ---I used getlocale.sh with rxvt and it worked for me, I can not reproduce the problem.

--- End quote ---
Thanks for trying to reproduce it, andyj, and for clarifying that the TERM variable value is set by upstream developers and not by the TCL packager (you). I'm puzzled that the issue affects my rig but not yours. Very mysterious. If I find an explanation, I'll make a follow-up post in this thread.

Navigation

[0] Message Index

[#] Next page

Go to full version