Brad Bruce
Brad Bruce

Reputation: 7807

How do I publish a ClickOnce install in MSBUILD (VS2005) that goes to the proper directory and does NOT create a setup.exe?

I'm trying to automate publishing a click once application.

I am using VS2005.

I have been able to deploy properly from VS, but not from the command line.

Here is the line I'm using:

    C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\msbuild.exe 
/p:Configuration=Release
/t:Publish
/p:PublishUrl=C:\source\deploy\
/p:PublishDir=c:\source\deploy\
/p:ApplicationVersion=1.2.3.5
"c:\myproject\myproject.csproj"
  1. Instead of deploying to C:\source\deploy\MyProject it deploys to the bin folder inside my project. If I leave off the trailing slash, it deploys to c:\source\deploymyproject

  2. It creates a setup.exe. I assume this is for installing to the desktop instead of the web. Is this an indication of a problem, or can it be ignored?

Upvotes: 5

Views: 2947

Answers (1)

Gamlor
Gamlor

Reputation: 13238

  1. Building ClickOnce with MSBuild changes some behaviour of the parameters. Probably the same issue like in this and this Stack-Overflow questions.
  2. The setup.exe is fine, you can ignore it. The setup.exe is intended for installing the application on machines without the .NET-Framework installed. It checks first for .NET and can install it if missing. Afterwards the setup.exe just calls the regular ClickOnce installer. So you just can ignore it. It's not used by ClickOnce.

Upvotes: 3

Related Questions