• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 339
  • Last Modified:

C#, post build step

I have this folder structure.
e:\my solution
e:\my solution\build
e:\my solution\project1
e:\my solution\project2
.....
e:\my solution\project5

I would like each project to have a post build step that moves a copy of my dll-s to folder "my solution\build".
This script does not work
Copy $(TargetDir) $(SolutionDir)\build\
I have tried other variations.  Any suggestions?
Thanks
0
wilfordrocks
Asked:
wilfordrocks
2 Solutions
 
SriVaddadiCommented:
try this
Copy /y $(OutDir)*.* $(SolutionDir)build
 
0
 
Miguel OzSoftware EngineerCommented:
Try:
xcopy /R/Y $(TargetDir)$(TargetFileName) $(SolutionDir)\build

and make sure you build from the solution, not the individual project:
http://social.msdn.microsoft.com/Forums/en-US/msbuild/thread/915e0c76-8ecd-4a31-a5b2-aed5f3b0b4da/

an alternative to avoid issue above would be:
xcopy /R/Y $(TargetDir)$(TargetFileName) $(ProjectDir)..\build

0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now