Fwd: Added function - contract-path

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Fwd: Added function - contract-path

lahavav

Hi all,

I've added a function (A make function) named contract-path to the 3.80 sources.
It takes a path with garbage like 'dir/..' or 'dir1//2/' or 'dir/./dir2' and
contracts it as much as possible, e.g.:

a/b/..    ==> a
a/./.     ==> a
a\b\\c/d  ==> a/b/c/d

I found it very useful when I see up-and-down paths used in my makefiles.
Please let me know if anybody else is interested in it, and if desired I'll
commit it to the repository.

I've posted this message to all 3 maling lists to see if there's interest.
Comments are welcome since I've had a day's headache for doing this in linear
time.

Bye,
- Aviad Lahav




----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

----- End forwarded message -----




----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.



_______________________________________________
Help-make mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/help-make