Hi Dion Thank you for your response. Can you provide me a maven.xml snipped showing how to create a java.util.File? I failed trying to find out the right syntax.
Best Regards Silvio -----Original Message----- From: Dion Gillard [mailto:[EMAIL PROTECTED] Sent: Montag, 5. September 2005 12:34 To: Maven Users List Subject: Re: "x:parse" with absolute filename does not work OR "How to load/parse an xml file using absolute filename (based on Windows)"? Create a java.io.File using ${basedir}/Foo/baar and then get the URL from it. On 9/5/05, Haldi, Silvio <[EMAIL PROTECTED]> wrote: > Hi all > I already posted the message regarding parsing an xml file using x:parse > tag (see below). > Up to now I did not receive any message that helps solving the problem. > I can't believe that nobody already ran into the same problem. > > How can I use an file URL based on the basedir variable in x:parse?? > File://${basedir)/foo/baar does NOT work on my WINDWOS machine (error > message see below)! > I cant use relative Pathes, especially in a multiproject environment > (using project.xml inheritance). > > Can anybody help me? Is there any workaround (beside the x:parse tag), > for example using the ANT task loadFile (which runs with absolute file > names (also with non-URL syntax))? > > Many Thanks > Silvio > > -----Original Message----- > From: Haldi, Silvio [mailto:[EMAIL PROTECTED] > Sent: Donnerstag, 1. September 2005 18:33 > To: Maven Users List > Subject: RE: "x:parse" with absolute filename does not work > > If I do this I receive the following message: > > BUILD FAILED > File...... c:\myProject\component\maven.xml > Element... x:parse > Line...... 62 > Column.... 110 > c Nested exception: c > > Please note that I'm using windows. > The statement in maven.xml is now: > > <x:parse var="myFile" xml="file://${basedir}/../mydir/myFile.xml"/> > > and the path resolved looks similar too: > file://c:\myProject\component/../mydir/myFile.xml > > Cheers > Silvio > > > -----Original Message----- > From: Kenney Westerhof [mailto:[EMAIL PROTECTED] > Sent: Donnerstag, 1. September 2005 16:00 > To: Maven Users List > Subject: Re: "x:parse" with absolute filename does not work > > On Thu, 1 Sep 2005, Haldi, Silvio wrote: > > x:parse expects an URL, so prefix the filename with 'file://'. > > > Hi > > I wan't to parse an XML document on my filesystem using the parse tag > > from the XML Jelly-library. > > If I specify the source XML file by an absolute Path it does not work. > > It seems that the parse tag is expecting a relative (to ${basedir}) > > path. > > > > I want to to something like this: > > > > <x:parse var="myFile" xml="${basedir}/../mydir/myFile.xml"/> > > > > How can I do this? > > > > Thanks > > Silvio > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > -- > Kenney Westerhof > http://www.neonics.com > GPG public key: http://www.gods.nl/~forge/kenneyw.key > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- http://www.multitask.com.au/people/dion/ "You are going to let the fear of poverty govern your life and your reward will be that you will eat, but you will not live." - George Bernard Shaw --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
