summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib/idle.pyw
diff options
context:
space:
mode:
authorKurt B. Kaiser <kbk@shore.net>2002-12-24 06:36:19 (GMT)
committerKurt B. Kaiser <kbk@shore.net>2002-12-24 06:36:19 (GMT)
commitf4f427681507371f70ef904a248420ef15dba2a8 (patch)
tree147b87610fef611eb57db81a4a34c49781c45ab7 /Lib/idlelib/idle.pyw
parent12bf339aea9c787f7ce655d613b8898f7511c7db (diff)
downloadcpython-f4f427681507371f70ef904a248420ef15dba2a8.zip
cpython-f4f427681507371f70ef904a248420ef15dba2a8.tar.gz
cpython-f4f427681507371f70ef904a248420ef15dba2a8.tar.bz2
M PyShell.py
M idle M idle.py M idle.pyw M setup.py Switch back to installing IDLE as a package. The IDLE GUI and the subprocess will both attempt to start up via the package mechanism, but if IDLE is not yet installed it is possible to run by calling python idle.py in the IDLE source directory, or to add the source directory to sys.path. One advantage of doing it this way is IDLE stays off sys.path. Developed in collaboration with Tony Lownds.
Diffstat (limited to 'Lib/idlelib/idle.pyw')
-rw-r--r--Lib/idlelib/idle.pyw9
1 files changed, 7 insertions, 2 deletions
diff --git a/Lib/idlelib/idle.pyw b/Lib/idlelib/idle.pyw
index 8638a16..131e8d3 100644
--- a/Lib/idlelib/idle.pyw
+++ b/Lib/idlelib/idle.pyw
@@ -1,4 +1,9 @@
#! /usr/bin/env python
-import PyShell
-PyShell.main()
+try:
+ import idlelib.PyShell
+ idlelib.PyShell.main()
+except:
+ # IDLE is not installed, but maybe PyShell is on sys.path:
+ import PyShell
+ PyShell.main()