Announcements and discussions for Gnus, the GNU Emacs Usenet newsreader
 help / color / mirror / Atom feed
* mail back to UTF-8 before save to HD
@ 2016-02-04  3:37 Emanuel Berg
  2016-02-04  7:45 ` Peter Münster
  0 siblings, 1 reply; 17+ messages in thread
From: Emanuel Berg @ 2016-02-04  3:37 UTC (permalink / raw)
  To: info-gnus-english

(case 1) If I write a mail with the Swedish chars "å",
"ä", or "ö", as in

    äåö
    ÅÅÖ

the mail gets the headers:

    Content-Type: text/plain; charset=utf-8
    Content-Transfer-Encoding: quoted-printable

(case 2) But if I don't use any of them chars, there
is only:

    Content-Type: text/plain

However when the mail from (case 1) is archived in my
nnml group mail.sent, the UTF-8 isn't restored but the
"quoted-printable" style remains:

    =C3=A4=C3=A5=C3=B6
    =C3=84=C3=85=C3=96

I wrote this zsh to restore it:

    back-to-swedish () {
        local files=($@)
        sed -e 's/=C3=A5/å/g; s/=C3=A4/ä/g; s/=C3=B6/ö/g' \
            -e 's/=C3=85/Å/g; s/=C3=84/Å/g; s/=C3=96/Ö/g' \
            -e 's/=20/ /g' $files
    }

(I don't know why the whitespace at the end of the
signature delimiter must be restored as well. It gets
sent and archived as =20.)

My question is, how can I automatize this so the UTF-8
is restored automatically if it was used in the
original message?

-- 
underground experts united
http://user.it.uu.se/~embe8573


_______________________________________________
info-gnus-english mailing list
info-gnus-english@gnu.org
https://lists.gnu.org/mailman/listinfo/info-gnus-english

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2016-02-07  3:31 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-04  3:37 mail back to UTF-8 before save to HD Emanuel Berg
2016-02-04  7:45 ` Peter Münster
2016-02-04 21:32   ` Emanuel Berg
2016-02-05 18:42   ` Emanuel Berg
2016-02-05 18:59     ` Teemu Likonen
2016-02-06  0:20       ` Emanuel Berg
2016-02-06  2:11         ` Adam Sjøgren
2016-02-06  2:15           ` Emanuel Berg
2016-02-06 14:23             ` Adam Sjøgren
2016-02-06 21:47               ` Emanuel Berg
2016-02-06 21:56                 ` Adam Sjøgren
2016-02-06 22:17                   ` Emanuel Berg
2016-02-06 22:34                     ` Adam Sjøgren
2016-02-07  3:21                       ` Emanuel Berg
2016-02-07  3:31                         ` Emanuel Berg
2016-02-06  6:57         ` Teemu Likonen
2016-02-06 21:36           ` Emanuel Berg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).