Obtaining the destination of a symbolic link
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Obtaining the destination of a symbolic link
- From: Dirk Laurie <dirk.laurie@...>
- Date: 2016年6月21日 00:23:14 +0200
The symbolic link yyy points to zzz.
I want to get zzz given yyy. The follwing code does it if ypu have bash.
print (io.popen"ls -l yyy":read():match"->%s*(.*)$")
Is there a system-independent way? Tried lfs; failed.