From: <syl...@po...> - 2003-11-14 06:46:33
|
On Fri, Nov 14, 2003 at 02:33:34PM +0900, Nicolas Cannasse wrote: > Hi list, > I came up very recently with a typical problem. > I had a file A and its relative path, I had a file B and its absolute path, > I wanted to get the file B path relative to A.... not so easy actually. I > wrote this small module Path : > > Path.make "my/../path/./" build a relative path > Path.absolute give the absolute path > Path.relative a b give the path of a relative to b > Path.up goes up one directory > > I did some tests under windows , it looks like it works well. If people can > test it under *nix... > > Note : this does not actually do any system checking ( the path may not > exists or contains invalid characters ). Only special paths . .. and / ( and > windows drive letters ) are recognized as special. > > Nicolas Cannasse Hello, In fact, i have exactly the same module for Unix ( but i need to call it SysPath ). Are you interested in fusionning your module with mine ? I had also SysUtil which try to implement some common unix function ( find, which, mkdir, test... ) in SysUtil. I am really interested in fusioning your module with mine, because i want fileutils ( my module ) to be able to work on every platform. Kind regard Sylvain LE GALL |