• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Quoted-Printable Perl Module
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Quoted-Printable Perl Module


  • Subject: Quoted-Printable Perl Module
  • From: Christopher Stone <email@hidden>
  • Date: Thu, 16 Mar 2017 18:27:06 -0500

Hey Folks,

For some while I've been faunching about dealing with quoted-printable in AppleScript.

Shane came up with some find/replace ASObjC, but that just doesn't cut it.

I'm really surprised there's not a specific method in ASObjC for dealing with it, but c'est la vie.

So – I'm currently looking at a Perl module that manages QP (and other encodings) quite neatly.

http://search.cpan.org/~dskoll/MIME-tools-5.508/lib/MIME/Decoder.pm

#!/usr/bin/env perl -sw
    use MIME::Decoder;

$decoder = new MIME::Decoder 'quoted-printable' or die "unsupported";
$decoder->decode(\*STDIN, \*STDOUT);

This works perfectly for STDIN-->STDOUT, but I don't understand how to make it work with simple scalar variable input/output.

Presently I'm running it as a text-filter in BBEdit.

Ultimately I want to make it work from an AppleScript that takes its source from an email in Apple Mail and outputs to a variable.

Can someone help?

--
Best Regards,
Chris

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Quoted-Printable Perl Module
      • From: debt <email@hidden>
  • Prev by Date: add notes to pdf on local os x webserver
  • Next by Date: Re: Quoted-Printable Perl Module
  • Previous by thread: add notes to pdf on local os x webserver
  • Next by thread: Re: Quoted-Printable Perl Module
  • Index(es):
    • Date
    • Thread