SO_RE = re.compile(r'^\.so\s+(.*)$')
def process_file(name):
- m = MAN_NAME_RE.search(name)
+ full_name = os.path.abspath(name)
+ m = MAN_NAME_RE.search(full_name)
if not m:
return False
category = m.group(1)
link = '../' + link
os.unlink(name)
os.symlink(link, name)
- print 'Converted {} into a symlink to {}'.format(name, link)
+ print 'Converted {} into a symlink to {}'.format(full_name, link)
return True
def main(args=[]):