Problem with external Visual Studio tools
Visual studio 2005: I am transitioning from post build event to using external tool menu with batch file.
I used to have
cd "$(ProjectDir).."
for /f "tokens=2,3,4 delims=/ " %%a in ('date /t') do set bdate=%%c.%%a.%%b
pkzipc -add -overwrite -dir=current "Z:\Technology\VisualStudio2005\Project Zips\$(ProjectName)_%bdate%_%username%.zip" "$(ProjectDir)*"
When I try to use this as an external tool it wraps "around" the project name and adds an additional file \ to the SolutionDirectory (I'm not sure if I want the project or solution dir to continue and doesn't work)
The code I'm trying to use:
pkzipc -add -overwrite -dir=current Z:\Technology\VisualStudio2005\Project Zips\%2\%2_%bdate%_%username%.zip %1*
this code doesn't work, I think the first part, stripping the outer "", answers that it leaves extra \ at the end of the projectdir variable. How can I fix this?
a source to share
You are probably installing the external tool incorrectly, you need to give the full path to pkzipc in the Command: field and put the arguments in the arguments :.
Also you don't have access to script parameters, so% 1% 2 won't work, you have to specify the following field:
-add -overwrite -dir=current "Z:\..\$(ProjectName)_%bdate%_%username%.zip" "$(ProjectDir)*"
a source to share