In Python, is there a function to check if a given file/directory is a symlink? For example, for the below files, my wrapper function should return True.
# ls -l
total 0
lrwxrwxrwx 1 root root 8 2012-06-16 18:58 dir -> ../temp/
lrwxrwxrwx 1 root root 6 2012-06-16 18:55 link -> ../log
To determine if a directory entry is a symlink use this:
For instance, given: