Bugs item #3098057, was opened at 2010-10-29 10:52
Message generated for change (Comment added) made by dogu
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=402868&aid=3098057&group_id=31650

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Tasks
Group: 0.91-alpha2
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: myrocode ()
Assigned to: Nobody/Anonymous (nobody)
Summary: <move> uses wrong relative path

Initial Comment:
I'm, usingNAnt 0.91 (Build 0.91.3881.0; alpha2; 17/08/2010) on Windows Server 
2008.
When using the <move> command i have noticed that the relative path is wrong if 
the file attribute starts with a /.
Here is how to reproduce the issue:

my build file is located at 
 --> C:\Users\Administrator\Documents\Nant Projects\Sampleproject\sample.build

if I use 
  ->  <delete file="\folder1\file1.txt" />
the file that is located at C:\Users\Administrator\Documents\Nant 
Projects\Sampleproject\folder\file1 is deleted correctly.

but if I use 
  -> <move file="\folder1\file1.txt" tofile="\folder2\file1.txt" />   it 
produces an error because it tries to access a wrong file path: 
c:\folder1\file1.txt

removing the backslash, makes the <move> task workingcorrecly.
  -> <move file="folder1\file1.txt" tofile="folder2\file1.txt" />   works 
correcty.. infact is uses C:\Users\Administrator\Documents\Nant 
Projects\Sampleproject\folder\file1.


I have reported this as a bug because all the tas's relative paths are accessed 
using the backslah except this one.




----------------------------------------------------------------------

>Comment By: Dominik Guder (dogu)
Date: 2011-09-25 22:43

Message:
Basically I would not use relative paths starting with "\" since i doubt
windows will use it in same way as I think. 
To narrow this somewhat could you please try copy task with your relative
path?

As  an overall option I want to suggest to use either relative paths
without "\" or put a dot infront of: "\folder1\file1.txt" would become
".\folder1\file1.txt" Then it should waork again.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=402868&aid=3098057&group_id=31650

------------------------------------------------------------------------------
All of the data generated in your IT infrastructure is seriously valuable.
Why? It contains a definitive record of application performance, security
threats, fraudulent activity, and more. Splunk takes this data and makes
sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-d2dcopy2
_______________________________________________
nant-developers mailing list
nant-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-developers

Reply via email to