summaryrefslogtreecommitdiffstats
path: root/Mac
diff options
context:
space:
mode:
authorJust van Rossum <just@letterror.com>2002-10-20 17:14:28 (GMT)
committerJust van Rossum <just@letterror.com>2002-10-20 17:14:28 (GMT)
commit7aa7f2eb0d87e23f218a0a813527f28ac4a4d228 (patch)
tree9cf51c191838e956d7cad667356a3bdab45e58b1 /Mac
parent8fce2ef84c1c1a421d36c84aa6e612bb4ad9a055 (diff)
downloadcpython-7aa7f2eb0d87e23f218a0a813527f28ac4a4d228.zip
cpython-7aa7f2eb0d87e23f218a0a813527f28ac4a4d228.tar.gz
cpython-7aa7f2eb0d87e23f218a0a813527f28ac4a4d228.tar.bz2
cd to users home dir if no current dir has been set. Fixes bug #625734
Diffstat (limited to 'Mac')
-rw-r--r--Mac/Tools/IDE/PythonIDEMain.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/Mac/Tools/IDE/PythonIDEMain.py b/Mac/Tools/IDE/PythonIDEMain.py
index fb02100..44fea3c 100644
--- a/Mac/Tools/IDE/PythonIDEMain.py
+++ b/Mac/Tools/IDE/PythonIDEMain.py
@@ -43,6 +43,11 @@ class PythonIDE(Wapplication.Application):
self.quitevent)
import PyConsole, PyEdit
Splash.wait()
+ if sys.platform == "darwin":
+ if sys.argv and sys.argv[0].startswith("-psn"):
+ home = os.getenv("HOME")
+ if home:
+ os.chdir(home)
# With -D option (OSX command line only) keep stderr, for debugging the IDE
# itself.
debug_stderr = None