[Python-checkins] CVS: python/dist/src/Lib/plat-riscos riscospath.py,1.4,1.5
Guido van Rossum
gvanrossum@users.sourceforge.net
Mon, 17 Sep 2001 08:16:11 -0700
- Previous message: [Python-checkins] CVS: python/dist/src/Lib dospath.py,1.23,1.24 macpath.py,1.29,1.30 ntpath.py,1.41,1.42 posixpath.py,1.43,1.44
- Next message: [Python-checkins] CVS: python/dist/src/Doc/lib libposixpath.tex,1.18,1.19
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/python/python/dist/src/Lib/plat-riscos
In directory usw-pr-cvs1:/tmp/cvs-serv22193/Lib/plat-riscos
Modified Files:
riscospath.py
Log Message:
SF patch #461781 by Chris Lawrence: os.path.realpath - Resolve symlinks:
Once upon a time, I put together a little function
that tries to find the canonical filename for a given
pathname on POSIX. I've finally gotten around to
turning it into a proper patch with documentation.
On non-POSIX, I made it an alias for 'abspath', as
that's the behavior on POSIX when no symlinks are
encountered in the path.
Example:
>>> os.path.realpath('/usr/bin/X11/X')
'/usr/X11R6/bin/X'
Index: riscospath.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/plat-riscos/riscospath.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** riscospath.py 2001/07/20 18:54:44 1.4
--- riscospath.py 2001/09/17 15:16:09 1.5
***************
*** 316,319 ****
--- 316,323 ----
+ # realpath is a no-op on systems without islink support
+ realpath = abspath
+
+
# Normalize a path. Only special path element under RISC OS is "^" for "..".
- Previous message: [Python-checkins] CVS: python/dist/src/Lib dospath.py,1.23,1.24 macpath.py,1.29,1.30 ntpath.py,1.41,1.42 posixpath.py,1.43,1.44
- Next message: [Python-checkins] CVS: python/dist/src/Doc/lib libposixpath.tex,1.18,1.19
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]