Sjur
Sjur

Reputation: 91

Publish Web to file system from Visual Studio 2010 does nothing but delete

When I try to publish in Windows 7 from Visual Studio 2010 via File System, no files are added to my target folder. If I choose "Replace matching files with local copies", nothing happens. If I choose "Delete existing files prior to publish", it deletes the files in the target folder, but no new files are published. This is the output I get:

Deleting existing files...

Publishing folder /...

========== Build: 3 succeeded or up-to-date, 0 failed, 0 skipped ==========

========== Publish: 1 succeeded, 0 failed, 0 skipped ==========

Any thoughts?

EDIT: Forgot to mention that I'm running VS as an Administrator. If I don't, publish will explicitly fail.

Upvotes: 9

Views: 3138

Answers (4)

Nikos Tsokos
Nikos Tsokos

Reputation: 3356

I had the same problem just after installing the latest windows azure SDK.

The solution was to match the build configuration with the publish configuration. In my case i was building for "Debug - Mixed platforms" and publishing for "Debug - Any CPU"

Credit goes to the following: http://geekswithblogs.net/ToStringTheory/archive/2012/06/11/lsquopublishhelliprsquo-resulting-in-directory-with-no-files.aspx

Upvotes: 1

Nigel Findlater
Nigel Findlater

Reputation: 1724

This happened to me too. To solve this:

  • Open the control panel, click the programs icon and remove web publish
  • In VS2010 click the tools drop down menu and select Install Web Components

I am not sure why this happened but I suspect that the VS2012 installation could have upgraded the web deploy component when I was working with Azure Web Sites in VS2012.

UPDATE: This stopped working the next day! Now I am publishing the application through VS2012.

Upvotes: 0

Matt Jordan
Matt Jordan

Reputation: 91

I ran into the same problem, after checking publish output, event logs, turning on and checking visual studio logs etc I then decided to remove the web publish (via add/remove) which I believe had been recently updated to v1.0.30810.0. This resolved the problem.

Upvotes: 5

Brian Rogers
Brian Rogers

Reputation: 142

I hope this issue has been resolved in the meanwhile, but something similar happened to me recently. In my case, the Build Action of the file had somehow been set to None. If the Build Action of a file is set to None, Publish Web will skip the file. To check the Build Action, select the file in the Solution Explorer and press F4 to go to the Properties Window.

Upvotes: 1

Related Questions