In the python installation on my PC there is a sweet script in c:\python26\tools\scripts called redemo.py. It's a simple tk app for testing regular expressions. I wish I could get it--or something like it--running on my Mac, but I don't know how. The script doesn't appear to be part of the python installation on my mac. Ideas?
A:
Install python on your mac, then copy the script over? It should work fine on any python installation.
Donnie
2009-11-28 01:27:08
Python should already be installed on Mac OS X. At least it is on mine, but then again I installed the developer tools.
Paul Tomblin
2009-11-28 01:30:03
Yes, it is a standard component on OS X.
Ned Deily
2009-11-28 01:45:03
A:
Mac OS X comes with Python pre-installed. As of 10.6.2 it has Python 2.6.1 found at /usr/bin/python
. Copy redemo.py to your Mac. Make sure you have X11.app running and open a terminal (Terminal.app is available by default) and just run:
% python /path/to/redemo.py
Assuming there aren't any Win32 specific hooks in this script, it should execute.
jathanism
2009-11-28 01:34:22
A:
Python is part of OSX, but sometimes it's a bit out of date: http://www.python.org/download/mac/
songdogtech
2009-11-28 01:35:55
That script directory is not included in the OS X Python installer installations.
Ned Deily
2009-11-28 01:38:56
+3
A:
You can view the script directly from the python svn repository here and can download it:
curl http://svn.python.org/view/*checkout*/python/trunk/Tools/scripts/redemo.py?content-type=text%2Fplain > redemo.py
/usr/bin/python redemo.py
It seems to work just fine as is on OS X 10.6 with python 2.6.
Ned Deily
2009-11-28 01:44:01