ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jeff Tulley" <JTUL...@novell.com>
Subject RE: Refactor of PathTokenizer - am I missing something?
Date Thu, 03 Jan 2002 17:32:58 GMT
I guess regardless of everything, my changes makes the test code blow up
completely.  We either need to re-evaluate what the behavior should be
and get the tests correct, or I am just completely wrong here anyway. 
Given that I am extremely new to Ant, and that this is probably
long-standing behavior that couldn't be changed, I'm guessing that I
need to come up with some sort of solution that maintains current
behavior.

I need to let my brain churn on this for a little while.

It looks like from the test code(PathTest.java), that the following
things are true:
1) for unix style paths (/a:/b) on Windows, a drive letter is tacked on
(maybe the current working drive)
2) same behavior with a backslash.
3) for windows style paths (c:\\test), unix is unable to meaningfully
resolve them, it becomes "/c" and "/test"
4) once again, same behavior with a backslash.

I'll try to get something that preserves this functionality while
adding support for multiple-character drive/volume names.

Jeff Tulley  (jtulley@novell.com)
(801)861-5322
Novell, Inc., the leading provider of Net services software.

>>> holtdl@yahoo.com 1/2/02 5:39:49 PM >>>
--- Jeff Tulley <JTULLEY@novell.com> wrote:
> If the build file is system independent, how would
"/usr/bin/somedir"
> get translated on Windows?  I can see that relative paths should get
> resolved correctly, but absolute paths will always be, by definition,
OS
> dependent.

I look to Ant to deal with path-separator/file-separator independence,
which it does quite nicely (I hate typing backslashes :). Putting a
hard-coded full-path into any type of build-file (for
Ant/Make/Jam/whatever) is just asking for trouble -- that's what
properties/variables are for. I don't think trying to make Ant jump
through hoops so it can deal with that sort of thing is necessary,
since
it already allows for reading in property files, which is where that
sort
of information should go (and if someone really really wants to put a
full-path into the build-file, there's always <pathconvert>).

Diane

=====
(holtdl@yahoo.com)



__________________________________________________
Do You Yahoo!?
Send your FREE holiday greetings online!
http://greetings.yahoo.com 

--
To unsubscribe, e-mail:  
<mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail:
<mailto:ant-dev-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message