[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


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 "..".