Open jvollme opened 6 years ago
Current working directory
means that a new IPython console (not terminals) will use the cwd of currently focused console, not that Spyder will use the cwd from the terminal it was started. For that, please use our -w
option:
spyder -w . ./template.py
However, that option seems to be failing right now (I thought it was working correctly). We'll take a look a this problem in a future release.
Thanks, so I simply misunderstood the "working directory" setting. Setting the cwd via the drop-down menu over the terminal will do for now then.
@ccordoba12 I looked at this. It seems that if Project Explorer isn't open, then it will use the path from the CLI option -w
. However, an open project will override that and become the working directory.
Yep, that's right. Do you plan to work on this?
What should the behavior be? -w
takes precedence over anything else?
Hard question... What do you think? @jvollme?
Problem Description
Terminal always assumes home directory, even though "current working directory" was selected in "Preferences"
What steps will reproduce the problem?
mkdir test
cd test
spyder
import os
andos.getwcd()
Same result occurs if a template file is already created at desired location:
cd test
spyder ./template.py
import os
andos.getwcd()
What is the expected output? What do you see instead?
extpected output: Current Working Directory (
/home/myhome/test
)actual output: Home directory (
/home/myhome
)Package Versions