[EMAIL PROTECTED] wrote: > Robert Kern wrote: > >>Why not copy cmd.py into your package under a different name? > > It offends my sense of modularity. For the record, I'm trying to use > pdb, the debugger, which in turn uses cmd. So it would be a matter of > taking pdb.py and hacking it to import a renamed version of cmd... kind > of messy and not a very good longterm solution. That's not to say I > won't resort to it if no better options are forthcoming.
A solution more kind to your sensibilities might be to make an auxiliary package alongside (rather than inside) yours. No modification to source necessary. pystdlib/ __init__.py cmd.py pdb.py Python 2.4.1 (#2, Mar 31 2005, 00:05:10) [GCC 3.3 20030304 (Apple Computer, Inc. build 1666)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> import pystdlib >>> from pystdlib import pdb >>> pdb.cmd.__file__ 'pystdlib/cmd.py' >>> -- Robert Kern [EMAIL PROTECTED] "In the fields of hell where the grass grows high Are the graves of dreams allowed to die." -- Richard Harter -- http://mail.python.org/mailman/listinfo/python-list