More elegant way to cwd?
Georg Brandl
g.brandl at gmx.net
Tue Dec 28 10:19:23 EST 2004
M.E.Farmer wrote:
> Peter Hansen wrote:
> [snip]
>> Other than using os.pardir instead of '..', and possibly adding
>> an "os.path.abspath()" call to the last bit (or does realpath
>> already do that? It's unclear from the docs)
> [snip]
> I believe os.path.abspath and os.path.realpath are the same.
> realpath is just an alias for abspath.
Yes, on Windows. On UNIX systems, realpath resolves symbolic links while
abspath doesn't.
mfg
Georg
More information about the Python-list
mailing list