[Pythonmac-SIG] Calling diff from MacPython

Jack Jansen Jack.Jansen@oratrix.com
Fri, 13 Sep 2002 21:25:19 +0200


On vrijdag, september 13, 2002, at 08:40 , Robin Siebler wrote:

> I need to compare to files and find out where they are 
> different.  Using diff seems to be a much better/faster choice 
> compared to using cmp().  How would I call the *nix command 
> diff from MacPython?  The MacPython version of os has no 
> system() call.

This is pretty much impossible, I think. It could be 
implemented, by using the CFM->MachO bridge and calling system() 
from libc through that, but unless someone can donate working 
code (in the form of a CFM system() routine that I can just drop 
in, and that will return a decent error on OS9) I couldn't be 
bothered to implement this. MacPython-OS9 is a dead end anyway.

--
- Jack Jansen        <Jack.Jansen@oratrix.com>        
http://www.cwi.nl/~jack -
- If I can't dance I don't want to be part of your revolution -- 
Emma Goldman -