1 ! Copyright (C) 2008 Slava Pestov.
2 ! See http://factorcode.org/license.txt for BSD license.
3 USING: io.backend io.files io.files.links io.pathnames kernel
4 sequences system unix unix.ffi ;
5 IN: io.files.links.unix
8 normalize-path [ symlink ] unix-system-call drop ;
10 M: unix make-hard-link
11 normalize-path [ link ] unix-system-call drop ;
14 normalize-path read-symbolic-link ;
16 M: unix resolve-symlinks
18 [ append-path dup exists? [ follow-links ] when ] reduce ;