Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 7aa7f2e

Browse files
committed
cd to users home dir if no current dir has been set. Fixes bug #625734
1 parent 8fce2ef commit 7aa7f2e

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

Mac/Tools/IDE/PythonIDEMain.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,11 @@ def __init__(self):
4343
self.quitevent)
4444
import PyConsole, PyEdit
4545
Splash.wait()
46+
if sys.platform == "darwin":
47+
if sys.argv and sys.argv[0].startswith("-psn"):
48+
home = os.getenv("HOME")
49+
if home:
50+
os.chdir(home)
4651
# With -D option (OSX command line only) keep stderr, for debugging the IDE
4752
# itself.
4853
debug_stderr = None

0 commit comments

Comments
 (0)