file readlink
Gives the target of a symbolic link; not available in ztcl.
file readlink NAME
Description
In Tcl, gives the path that the link NAME points at. In ztcl each call is an error.
Arguments
| Argument | Type | Default | Description |
|---|---|---|---|
| NAME | path | required | The path of the link. |
Returns
An error in ztcl.
Examples
% catch {file readlink n.txt}
1
Errors
% file readlink n.txt
could not readlink: links are not available in the root folder
-errorcode POSIX EACCES {permission denied}
Differences from Tcl
- Tcl 8.6.16 and 9.0.4 read links (issue 687).
Facts
- Capability
file. A new interpreter does not have it until the host turns it on.- Tcl release
- Tcl 9.1 and 8.6.
- Since
- ztcl 1.0.0-beta.1