I have been working on building a packaging utility which basically gets all added/modified files between two SVN revisions, then copies them locally and zips them.So far, I have been able to successfully extract all changed files between two revisions.
To go further, I am using xcopy to recursively create folders at a certain directory.
Assuming that the following files have changed when I check two revisions using svn diff command
/temp1/temp2/temp3/temfile.txt
/temp1/temp21/temp31/tempfile.txt
/temp1/temp2/ (folder created)
/temp1/temp2/temp3 (folder created)
For XCopy to work, I am doing
xcopy local/svn/copy/path d:/{folderpath}
where folderpath needs to be extracted from the above changed list e.g.
xcopy "C:/LocalSVN/temp1/temp2/temp3/temfile.txt" "d:/temp1/temp2/temp3/"
I need to in my batch file, extract only the folder path and remove the file name.What is the best way to do it in a batch file?
Is there a different way to achieve what I am trying to do?