问题
Recently, I wrote a cross-browser plugin using Firebreath, and I made one installer for all browsers. I searched in stackoverflow for automatic plugin installation, and find a bunch of good answers,
FireBreath plugin automatic installation
Deploying a Firebreath plugin on a webpage without manual installation
Plugin Installation
Deployment of NPAPI plugin with minimal user steps
All answers points out that it needs users’ interaction to download and install the plugin.
My question is that does plugin upgrade follow the same process of first installation, which let users to download the latest installer and install it manually again? Is there any other options to make the plugin upgrade more automatically (less user interaction)?
I also searched this answer a little bit relevant, but it doesn’t tell the way to upgrade a plugin automatically.
firebreath plugin refresh after update
Or I should ask what is the best practice to upgrade firebreath plugin?
回答1:
Basically there is no good answer to your question, unfortunately. I have had in-place updates working for all browsers (updating in the browser without a restart), but it's fraught with difficulty and extremely fragile. I don't really recommend it.
Probably the cleanest update experience I've seen is by using Google Omaha to do the install and automatic updates in the background. The biggest downside to Omaha is that it's a beast to get set up and working; even just building it requires a lot of work, and then you have to customize a lot of constants and such.
The way I do it is just require that the user download and install an update (MSI or .DMG w/ applescript, depending on the platform) and then just tell them they'll have to restart their browser to get the new version. It's not clean, but it drastically reduces the support requirements.
来源:https://stackoverflow.com/questions/16402579/how-to-automatically-upgrade-a-firebreath-plugin