简体   繁体   中英

Visual Studio 2013 remote debugging, auto deploy?

When I tried remote debugging with Windows Store applications (Metro applications), it was very easy. In the Start drop down I could choose one of the remote computer. Then VS built the project and automatically deployed the executable to the remote computer and ran it. It felt as if it were local debugging.

Now that I want to try remote debugging with an Windows application (simple C# Windows Forms), it was not that easy. I read the following page: http://msdn.microsoft.com/en-us/library/vstudio/8x6by8d2(v=vs.110).aspx

Does this mean I have to copy the built exe to the remote computer manually every single time when I build the project? Is there any way to make it work easily just like the Windows Store apps? Possibly a third-party extension or something?

I recently set this up for a work project, and encountered your post after experiencing similar issues. I detailed my solution on my blog.

Remote Debugging with VS2015

I changed the output folder to be a network share that my debugging account has access to, and the project build just creates output at that location, making it available to the debugger. I simply press the play (Debug) button on my toolbar with the 'Remote Debug' profile selected.

  1. Open Configuration Manager for the solution
  2. Add a new configuration and name it appropriately. Select the box to automatically do so for all projects.
  3. Open the project properties of the executable project you wish to remotely debug.
  4. Ensure that the remote debugging profile is selected.
  5. Set the build output to the network share on the remote debugging computer.
  6. Set the remote debugging host address and port.

Does this mean I have to copy the built exe to the remote computer manually every single time when I build the project?

Yes.

Is there any way to make it work easily just like the Windows Store apps?

You can create a post-build event in which you can do practically everything. In this case you can set up a xcopy/robocopy command which would copy the stuff to a network location.

Possibly a third-party extension or something?

Don't think so.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM