Zulip Chat Archive
Stream: lean4
Topic: symlink
Eric Wieser (Jan 21 2025 at 14:01):
Is there a wrapper anywhere for the unistd.h
symlink()
function? Calling out to ln
via a subprocess is rather slow.
Henrik Böving (Jan 21 2025 at 14:10):
No, it's also a bit non trivial because windows does of course not have unistd.h
. It would probably be added in through https://docs.libuv.org/en/v1.x/fs.html#c.uv_fs_symlink with the callback set to NULL
such that the request completes synchronously.
Eric Wieser (Jan 21 2025 at 16:50):
Relatedly, is there an analog to python's os.path.islink
? Using (← p.metadata).type == .symlink
doesn't work because metadata
follows the link.
Last updated: May 02 2025 at 03:31 UTC