On 6/9/20 4:22 PM, enh via Toybox wrote: > is there anything clever about realpath --relative-to, or is it just a > textual thing? something like: > > do the regular realpath work > if (FLAG(relative_to)) { > if (result starts-with relative_to_str) { > remove prefix > } else { > add prefix of "../" * number of directories in relative_to_str > } > }
Sadly, there is a little bit of clever: ln -s /usr/bin walrus ls walrus/.. I tried ot get this right for cp -s but have failing test cases, haven't cycled back around to it. Rob _______________________________________________ Toybox mailing list Toybox@lists.landley.net http://lists.landley.net/listinfo.cgi/toybox-landley.net