Re: base64 message body decode when replying???
Brent Welch <[email protected]>
| Newsgroups | gmane.mail.exmh.user |
|---|---|
| Message-ID | <[email protected]> |
>>>Andreas Wittkemper said:
>
> That is really great stuff. I wonder why such unquote command never made
it=
> into exmh.
> Looking for a solution for ages.
welch (me) has been busy with a startup for 10 years... I feel terrible
about my lack of ability to push out new versions of exmh...
> Unfortunately i am getting an error when using it.
>
> Still didn't learn tcl after all these years.
>
> text doesn't contain any characters tagged with "sel"
this is an unfriendly way of saying
"make a text selection, silly you"
The unquote command works on the current selection in the sedit window.
If you have a Multipart, it works to select from the
This is a multipart MIME ....
through to the end of the base64 or quoted-printable section,
and stop short of the next section you don't care about. The
focus will skip to the end after the unquote so you can more
easily select from there to the end of the buffer so you can
delete the unwanted text/html alternative or whatever.
> while executing
> "$t index "sel.first linestart""
> (procedure "SeditUnquote" line 6)
> invoked from within
> "SeditUnquote {.sedit2.f.t}"
> invoked from within
> ".sedit2.but.more.m invoke active"
> ("uplevel" body line 1)
> invoked from within
> "uplevel #0 [list $w invoke active]"
> (procedure "tk::MenuInvoke" line 50)
> invoked from within
> "tk::MenuInvoke .sedit2.but.more.m 1"
> (command bound to event)
>
> regards
>
> Andreas
>
>
> On 03/25/10 00:30, Brent Welch wrote:
> > Here's what I do:
> >
> > In the sedit More... menu I've added an Unquote menu item:
> >
> > *Sedit.Menubar.more.m.l_unquote: Unquote
> > *Sedit.Menubar.more.m.c_unquote: SeditUnquote {$t}
> >
> > The function SeditUnquote is in the attached file.
> > It's handles either quoted printable or base-64.
> > The QP decode is lame, and should probably use mimencode -u -q
> >
> > When I'm using a dumb terminal and using Repl directly,
> > I pipe contents of my vi buffer through an "un64" script
> > I wrote. Also attached
> >
> >>>> [email protected] said:
> > >
> > >
> > > > >That makes sense. Has anyone scripted a filter, maybe
triggered
> > > > >via ~/.mh_profile, which pre-formats the message before
handing
> > > > >off the content to the actual repl?
> > >
> > > Yes. Here's something I wrote back in '04. I think it should do
> > > what you want. If someone figures out how to make ~/.mh_profile
> > > configure repl to "do the right thing" let me know. I don't care
> > > that much--I just invoke it on demand (maybe once or twice a
week.)
> > >
> > > Looked at Sylpheed last week. Bah. I wonder if EXMH will last
> > > forever?
> > >
> > > steve
> > > --
> > >
> > > #!/bin/bash
> > > repl -filter /dev/null -nodraftfolder -nowhatnowproc $*
> > > (cat ~/Mail/draft; echo -e "\n> ---- Original Message ----" ; \
> > > mhshow cur -type text -nopause -nomoreproc \
> > > | egrep -v '^Return-Path|^Delivery-Date|^part[ ]+text/plain' \
> > > | egrep -v '^X-|^MIME' \
> > > | sed 's/^/> /' \
> > > )> ~/Mail/drafts/999
> > > comp -use -draftfolder drafts -draftmessage 999
> > > rm -f ~/Mail/draft
> > > rm -f ~/Mail/drafts/999
> >
--
Brent Welch
Director, Software Architecture, Panasas Inc
The Leader in Parallel Storage
www.panasas.com
[email protected]