create a symbolic link with the given value (pointing to another name).
def mksymlinkto(self, value, absolute=1):
origin: PosixMixin
where:
function source:
def mksymlinkto(self, value, absolute=1):
""" create a symbolic link with the given value (pointing to another name). """
if absolute:
self._callex(os.symlink, str(value), self.strpath)
else:
base = self.common(value)
# with posix local paths '/' is always a common base
relsource = self.__class__(value).relto(base)
reldest = self.relto(base)
n = reldest.count(self.sep)
target = self.sep.join(('..', )*n + (relsource, ))
self._callex(os.symlink, target, self.strpath)
called in /home/johnny/projects/merlinux/py/dist/py/path/local/testing/test_posix.py
traceback path.local.mksymlinkto.0
called in /home/johnny/projects/merlinux/py/dist/py/path/local/local.py
traceback path.local.mksymlinkto.1
called in /home/johnny/projects/merlinux/py/dist/py/path/local/testing/test_posix.py
traceback path.local.mksymlinkto.2
called in /home/johnny/projects/merlinux/py/dist/py/path/local/local.py
traceback path.local.mksymlinkto.3
called in /home/johnny/projects/merlinux/py/dist/py/test/rsession/testing/test_rsync.py
traceback path.local.mksymlinkto.4
called in /home/johnny/projects/merlinux/py/dist/py/path/local/testing/test_posix.py
traceback path.local.mksymlinkto.5
called in /home/johnny/projects/merlinux/py/dist/py/path/local/testing/test_posix.py
traceback path.local.mksymlinkto.6
called in /home/johnny/projects/merlinux/py/dist/py/path/local/testing/test_posix.py
traceback path.local.mksymlinkto.7
called in /home/johnny/projects/merlinux/py/dist/py/path/local/testing/test_posix.py
traceback path.local.mksymlinkto.8
called in /home/johnny/projects/merlinux/py/dist/py/test/rsession/testing/test_rsync.py
traceback path.local.mksymlinkto.9
called in /home/johnny/projects/merlinux/py/dist/py/path/local/testing/test_posix.py
traceback path.local.mksymlinkto.10
called in /home/johnny/projects/merlinux/py/dist/py/path/local/local.py
traceback path.local.mksymlinkto.11
called in /home/johnny/projects/merlinux/py/dist/py/path/local/local.py
traceback path.local.mksymlinkto.12
called in /home/johnny/projects/merlinux/py/dist/py/path/local/testing/test_posix.py