[REBOL] rebol file paths
From: arolls::idatam::com::au at: 5-Nov-2001 17:56
I just discovered an interesting property of
rebol file paths. Have a look at this console
>> what-dir ; == %/E/dev/rebol/view/local/
>> clean-path %/ ; reading this will list all your volumes
>> clean-path %// ; the root of your current directory
>> clean-path %/// ; the next directory along the path
== %/E/dev/ ; of your current directory
>> clean-path %//// ; etc
>> clean-path %/////
>> clean-path %//////
>> clean-path %/////// ; of course, going a bit too far...
** Access Error: Bad file path: ///////
** Where: clean-path
** Near: get-modes target 'full-path
>> clean-path %//////../
This also works for another volume.
Could be useful. Mmm.
I also noticed that rename cannot handle absolute
paths. It needs relative paths.
This is useful to know if you want to implement a
file move function (on the same volume).