readlink
Read and resolve symbolic link targets, or canonicalize paths. Outputs the resolved target or canonical path in JSON.
Instructions
Read the target of symbolic links, or canonicalize paths with --canonicalize. Read-only, no side effects. Use --canonicalize to resolve every component of the path. Returns JSON with the resolved target or canonical path. Use to inspect symlink targets or normalize paths. Not for full path resolution with existence checks — use 'realpath' which always resolves to an absolute, existing path. See also 'realpath'.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| canonicalize | No | Return canonical resolved paths. | |
| paths | Yes | Symlinks to inspect, or paths to canonicalize. | |
| raw | No | Write one target/path per line without a JSON envelope. | |
| strict | No | With --canonicalize, fail if a path does not exist. |