Title: Message

I think the underlying issue here is that encasing a folder/file target in a move with quotes behind the scenes won’t cause any issues, so that is what the developers did, but if you encase an entire exec command line in quotes in the task’s code, then you would probably still end up with the same problem.

 

The only way I can think that this could be resolved is if the exec task re-formatted all path type info on the command line to the 8.3 canonical form before moving on, but then again, that would make a large number of assumptions about what the command line is actually for and may cause other issues down the road.

 

I think that this is the best solution to use going forward, as it has the fewest number of questions.

 

Steve

 


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Kedziora, Rebecca
Sent: November 3, 2005 11:18 AM
To: nant-users@lists.sourceforge.net
Subject: RE: [Nant-users] Exec program can't handle dir name with spaces

 

Ah... the &quot worked!

 

Some places I don't have problems with the spaces in the dir name like when using the move task, but using it in a redirection of the exec task caused me grief.

 

Thanks

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Robert Schneider
Sent: Thursday, November 03, 2005 10:08 AM
To: nant-users@lists.sourceforge.net
Subject: RE: [Nant-users] Exec program can't handle dir name with spaces

Try to use quotes. Hope this helps.

 

"${buildlog.dir}\${source.changes.log.filename}"

 

 


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Kedziora, Rebecca
Sent: Thursday, November 03, 2005 4:55 PM
To: nant-users@lists.sourceforge.net
Subject: [Nant-users] Exec program can't handle dir name with spaces

 

A bug or not with nant .85 rc 3?

I am executing a program using the exec task as shown below:

                <exec program="${tools.bin.path}\changes.cmd"
               
commandline="${cc.root} ${cc.branch} ${cc.last.published.view.tstamp} ${cc.current.view.tstamp} > ${buildlog.dir}\${source.changes.log.filename}" failonerror="false"/>

As you can see I am piping my output to a file using >.  The problem I am having is if the directory has spaces that is being piped too it will not create the ${source.changes.log.filename}.  For example if my ${buildlog.dir} directory is  c:\builds\smc management center\logfiles it will not work.  If I use c:\builds\smc\logfiles it will work.

The work around I did was to move the file after it was created.

                <move file="${project.workingdir}\${source.changes.log.filename}" todir="${buildlog.dir}" overwrite="true" failonerror="false"/>

Is this a bug?

-Rebecca


This Message Scanned for Viruses by McAfee WebShield .

Reply via email to