Walt Mankowski on 3 May 2004 15:58:10 -0000


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: How to expand "../" in a path?


On Mon, May 03, 2004 at 11:22:14AM -0400, Chip Salzenberg wrote:
> According to Chip Salzenberg:
> > I'd probably do the rel2abs thing and then go all non-portable, since
> > ".." is kind of a Unixish thing anyway:
> > 
> > 
> > 
> 
> Oh hell, I was so busy with the syntax I screwed up the regex.
> Try this instead:
> 
>    s{ / [^/]+ / \.\. }{}xg

Chip,

Thanks for your help, but I ended up doing it another way.  It turns
out that Cwd::abs_path does exactly what I was looking for.

Walt

Attachment: signature.asc
Description: Digital signature