Hi.
I have a script located in /home/jBrandt/Code/python/ftest.py.
When I print the results of os.getcwd(), however, it gives me /home/jBrandt/Code as the current working directory. I realize that I could change the cwd, but the directory name will not be the same on all computers. I've also tried os.curdir, and all it returns is a single dot (wtf?)
Anyway, I need a tried-and-true method for getting the cwd; any help would be appreciated.
I have a script located in /home/jBrandt/Code/python/ftest.py.
When I print the results of os.getcwd(), however, it gives me /home/jBrandt/Code as the current working directory. I realize that I could change the cwd, but the directory name will not be the same on all computers. I've also tried os.curdir, and all it returns is a single dot (wtf?)
Anyway, I need a tried-and-true method for getting the cwd; any help would be appreciated.
Comment