Binhex4 Encoding

The binhex module

  • Encodes and decodes text in binhex format.
  • Commonly used to encode binary files on the Macintosh.

Encoding

     import binhex
     binhex.binhex(inputfile,outputfile)

Decoding

     import binhex
     binhex.hexbin(inputfile,outputfile)

Note

  • Macintosh resource fork ignored on non-mac systems.
<<< O'Reilly OSCON 2000, Advanced Python Programming, Slide 106
July 17, 2000, beazley@cs.uchicago.edu
>>>