LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices


Reply
  Search this Thread
Old 01-03-2022, 11:50 AM   #1
mfoley
Senior Member
 
Registered: Oct 2008
Location: Columbus, Ohio USA
Distribution: Slackware
Posts: 2,587

Rep: Reputation: 179Reputation: 179
can mailx show UTF-8 charsets?


I am using mailx as my email client (yes, I know ...). My Konsole session is set to use en_US.UTF-8, and the 'locale' command verifies that is being used -- and I can view, using cat, files containing UTF-8 characters.

I have tried with and without 'set ttycharset=UTF-8' in my .mailrc file. No matter what I try, when I read a message in mailx having a UTF-8 character, I get "[binary content]" as my message body.

Is it possible or not to read messages with mailx having UFT-8 characters?
 
Old 01-03-2022, 12:19 PM   #2
shruggy
Senior Member
 
Registered: Mar 2020
Posts: 3,677

Rep: Reputation: Disabled
I guess it depends on what mailx implementation is used. S-Nail should be able to understand UTF-8. Try it in lowercase
Code:
set ttycharset=utf-8
 
1 members found this post helpful.
Old 01-04-2022, 09:27 AM   #3
mfoley
Senior Member
 
Registered: Oct 2008
Location: Columbus, Ohio USA
Distribution: Slackware
Posts: 2,587

Original Poster
Rep: Reputation: 179Reputation: 179
Believe it or not, just changing "ttycharset=UTF-8" to lower case worked! Sheesh! The mailx man page says, "Best results are usually achieved when mailx is run in a UTF-8 locale on a UTF-8 capable terminal." Notice, NOT in lower case. The man page further reads,
Quote:
ttycharset
The character set of the terminal mailx operates on. There is normally no need to set this variable since mailx can determine
this automatically by looking at the LC_CTYPE locale setting; if this succeeds, the value is assigned at startup and will be
displayed by the set command. Note that this is not necessarily a character set name that can be used in Internet messages.
It apparently DOES NOT look at LC_CTYPE, as advertised! Furthermore, no mention that the ttycharset needs to be in lower case. You would think after all these centuries mailx would be pretty bug-free by now.

Thanks for this solution.

Last edited by mfoley; 01-04-2022 at 09:28 AM.
 
  


Reply

Tags
mailx, utf-8



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] "Snorkeling on an empty pipe": error in S-mailx (mailx 4.19.11) RandomTroll Linux - Software 0 11-30-2018 10:45 PM
TO ANYONE USING MAILX (mailx 12.1). stf92 Linux - Software 22 07-08-2010 09:44 PM
How do I know how a file is encoded? UTF-8, UTF-16, etc.. ?? brynjarh Linux - General 1 12-03-2004 11:11 AM
[Enter] in text documents diffrent on Windows and Linux? UTF-8/UTF-16 problem or? brynjarh Linux - General 1 11-24-2004 05:20 AM
X11 / UTF-8 locale seems missing 'fr_FR.UTF-8' chrsitophermann Debian 11 07-17-2004 02:04 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop

All times are GMT -5. The time now is 12:34 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration