简体   繁体   English

ClickOnce 通过 TFS 和发布管理

[英]ClickOnce through TFS & Release Management

I have seen quite a few blogs around managing a ClickOnce application through TFS up to Visual Studio 2010. The process seems a little convoluted and so I cannot help but wonder if there has been any improvement with later versions of VS?我看过很多关于通过 TFS 管理 ClickOnce 应用程序直到 Visual Studio 2010 的博客。这个过程似乎有点复杂,所以我不禁想知道 VS 的更高版本是否有任何改进? I am using 2015 (VS, TFS & RM) so would love to hear of anyone has had more luck doing this on later versions.我正在使用 2015(VS、TFS 和 RM),所以很想听到有人在以后的版本中这样做有更多的运气。

Any help on the matter would be massively appreciated!对此事的任何帮助将不胜感激!

These settings worked for me :这些设置对我有用:

/target:publish /p:PublishDir="$(build.artifactstagingdirectory)\\"/ /property:ApplicationVersion=1.0.0.$(Build.SourceVersion)

The $(Build.SourceVersion) variable will be the changeset / git commit id. $(Build.SourceVersion)变量将是变更集/git commit id。

在此处输入图片说明

在此处输入图片说明

Then you can create a release to deploy this somewhere.然后你可以创建一个发布来将它部署到某个地方。

  • Create a website to deploy to.创建要部署到的网站。
  • Click Artifacts to select the artifact to deploy.单击Artifacts以选择要部署的工件。
  • Select IIS Deployment to choose machines in a deployment group.选择IIS Deployment以选择部署组中的计算机。
  • Click the menu icon highlighted to select the drop folder.单击突出显示的菜单图标以选择放置文件夹。
  • For further documentation about certificates + signing see other clickonce docs.有关证书 + 签名的更多文档,请参阅其他 clickonce 文档。

I think there's another option to create an html page, but you can just link to the .application file.我认为还有另一种选择来创建 html 页面,但您可以链接到.application文件。

在此处输入图片说明

You could use the new build system vNext Build to achieve it.您可以使用新的构建系统 vNext Build 来实现它。 Just need to add Publish Build Artifacts step in the build process.只需要在构建过程中添加Publish Build Artifacts步骤即可。 You could write a PowerShell script, if you want to copy ClickOnce output to some directory like UNC path/IIS website folder.如果要将 ClickOnce 输出复制到某个目录(如 UNC 路径/IIS 网站文件夹),则可以编写 PowerShell 脚本。 Here is a blog with detailed steps: Building ClickOnce apps using build vNext这是一个包含详细步骤的博客: 使用 build vNext 构建 ClickOnce 应用程序

If you still insist on using XAML build, this one will also meet your needs.如果您仍然坚持使用 XAML 构建, 这个也将满足您的需求。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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