view tests/readlink.py @ 17247:6d51a0c71d4e stable

convert/svn: handle non-local svn destination paths (issue3142) test-convert-svn-sink.t still pass and I tested pushing to an svn+ssh repository
author Patrick Mezard <patrick@mezard.eu>
date Thu, 26 Jul 2012 12:07:55 +0200
parents 08a0f04b56bd
children 328739ea70c3
line wrap: on
line source

#!/usr/bin/env python

import errno, os, sys

for f in sys.argv[1:]:
    try:
        print f, '->', os.readlink(f)
    except OSError, err:
        if err.errno != errno.EINVAL:
            raise
        print f, 'not a symlink'

sys.exit(0)