简体   繁体   English

自动更新桌面应用

[英]automatically update desktop app

We have a web app and a desktop windows WPF app. 我们有一个Web应用程序和一个桌面Windows WPF应用程序。 Windows app sends data to webapp (hosted on azure) Windows应用程序将数据发送到webapp(托管在azure上)

Users download app from website. 用户从网站下载应用程序。 There are occasionally new versions of desktop apps available. 偶尔会有新版本的桌面应用程序可用。

What is the most efficient way to setup automatic updates for desktop app? 为桌面应用程序设置自动更新的最有效方法是什么? We are using github. 我们正在使用github。

I found "releases" in github but I'm not sure how to notify desktop app and how to create an updater. 我在github中找到了“发行版”,但不确定如何通知桌面应用程序以及如何创建更新程序。 (I guess we need to check for github releases every time app is started. Do I need to use Github api for this?) (我想我们每次启动应用程序时都需要检查github版本。为此我需要使用Github api吗?)

What is the best repository structure for releases? 什么是发布的最佳存储库结构?

I'm looking for best practicies on how to perform seamless updates to desktop apps. 我正在寻找有关如何对桌面应用程序进行无缝更新的最佳实践。 (In terms of repository setup, creating web api to pull version info maybe?) (就存储库设置而言,也许创建Web API来获取版本信息?)

You can deploy your desktop applications using ClickOnce Deployment mechanism. 您可以使用ClickOnce Deployment机制来部署桌面应用程序。 This will take care of updating the software. 这将负责更新软件。 Your users download the software from a publicly accessible Internet site. 您的用户从可公开访问的Internet站点下载软件。 Whenever you have a new version available, you can simply deploy the latest deployment files on the download link. 只要有可用的新版本,就可以简单地在下载链接上部署最新的部署文件。 ClickOnce deployed application automatically check for any updated version on that link and prompt the user to download and install the latest version. ClickOnce部署的应用程序会自动检查该链接上的任何更新版本,并提示用户下载并安装最新版本。

From the same MSDN link, one of the problems solved by ClickOnce deployment is facilitating automated updates: 通过同一MSDN链接,ClickOnce部署解决的问题之一是促进自动更新:

Difficulties in updating applications . 更新应用程序的困难 With Microsoft Windows Installer deployment, whenever an application is updated, the user must reinstall the whole application; 使用Microsoft Windows Installer部署,每当更新应用程序时,用户都必须重新安装整个应用程序; with ClickOnce deployment, you can provide updates automatically. 使用ClickOnce部署,您可以自动提供更新。 Only those parts of the application that have changed are downloaded, and then the full, updated application is reinstalled from a new side-by-side folder. 仅下载应用程序中已更改的那些部分,然后从新的并排文件夹中重新安装完整的更新的应用程序。

I was looking into accomplishing the same needs and came across this library which can do what you're asking for; 我一直在寻找满足相同需求的方法,并遇到了可以满足您要求的库。 https://github.com/Squirrel/Squirrel.Windows https://github.com/Squirrel/Squirrel.Windows

There's a lot of configuration, but what you're asking for is not trivial, but maybe you can get some ideas. 有很多配置,但是您要的并不是微不足道的,但是也许您可以得到一些想法。

For our needs; 为了我们的需要; we're going have our build server (teamcity) create an MSI using a Wix project then the app will download and execute the MSI. 我们要让构建服务器(teamcity)使用Wix项目创建MSI,然后该应用将下载并执行MSI。 Once we go to production we'll move MSI hosting over to some more enterprise-y CDN type setup. 一旦进入生产阶段,我们将把MSI托管移至更多企业级CDN类型设置。

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

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