[Pythonmac-SIG] mac islink()

Amos Newcombe anewcombe@earthlink.net
Fri, 5 May 2000 19:24:47 -0500


I read this from macpath.py:

># Return true if the pathname refers to a symbolic link.
># (Always false on the Mac, until we understand Aliases.)
>
>def islink(s):
>	return 0

I won't claim to understand Aliases but I did find the following to 
work for me:

import macfs
def islink(s):
	return macfs.ResolveAliasFile(s)[2]

Amos