Is there a NuGet equivalent for deploying content to end users?

痴心易碎 提交于 2020-01-31 09:36:46

问题


I have a c# application and I am mainly concerned with pushing out automatic updates to clients running my software. These updates can be anything from a new / patched dll to new resource file.

I know I can create a ClickOnce application to get part way there, but it doesn't allow much control as I would like (for example, I want to be able to easily "bundle" 3rd party components with my software or be able to have the user decide which components they want to have updated).

I see that programs like NotePad++ have a dedicated updater, but I'm hoping that I can piggy back from others as opposed to rolling my own updater from scratch.

What are my options?


回答1:


There are a few different ones you can check out.

This one has been talked about/around for awhile, but I haven't heard any news of wether or not it's actually ready to be used yet

https://github.com/Squirrel/Squirrel.Windows

https://www.nuget.org/packages/NuSelfUpdate/

https://www.nuget.org/packages/NuGetUpdate/

Would recommend this one, as last time I opened a ticket he addressed it almost immediately.

https://www.nuget.org/packages/Sidewinder.Core/

None of them will be a 100% drop in solution because application updating is one of those things that's hard to generalize.

For me what I end up doing is one of two things

1) Use http://www.myget.org to host my updates, and roll my own system that downloads/restarts/updates things.

2) Roll my own with a component index on AWS S3. The xml lists the components and points to the url to get each update. From there your application decides how/when to stop/update/restart it.

Also, if I'm updating the main application, generally how I do it(If the application is already running)

  1. Check for an update.
  2. If there is an update, download it.
  3. On start of the application, check for the update file locally.
  4. If it exists, install it silently

If the application isn't running I do an update check/download/install on start(but that's only when it's critical that people are running the absolute latest).

In the end though, none of those frameworks will 100% fit your needs, because no scenario is the same, hopefully they get you most of the way though.




回答2:


Building upon SLaks comment.

Chocolatey is a wrapper around nuget for installing apps, similar to the likes of app-get in the Linux world. It is a tool to wrap around all sorts of installers.

If your clients are happy running the command line, chocolatey is a good solution for publishing apps.

The WiX installer describes itself as "The most powerful set of tools available to create your Windows installation experience. Free and Open Source since 2004!" So depending on how sophisticated you want to go you may wish to take a look it also.



来源:https://stackoverflow.com/questions/22209184/is-there-a-nuget-equivalent-for-deploying-content-to-end-users

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!