From V2 to V3
This documentation will explain how to upgrade to the version 3 of auto-update.
First migrate to the last tooling:
Remove all your previous config:
to only let this:
⚠️ If you were using your server, with
autoUpdateURL
, I will upgrade this guide soon for you. Meanwhile, take a look at the new upload optionexternal
which allows you to send only the link of your zip, not the code in Capgo cloud. This has been made for companies with strict privacy policies. In external mode, the code will never land on Capgo server, we just store the URL and send it to the device, which will directly download it. In the standard way, the code is zipped and stored in our server, but we will never open it or use it either.
What change
All configurations become server-side for auto-update, to give you more control on how you send an update to users.
That allows us to revert, AB test, partial deploy or even deploy just to one user! These settings are added back to the web interface:
- disable revert under native
- disable update above major
⚠️ They will become true by default for all channels
This will also remove the need to update often the plugin, most updates will be done server side, and you will get it without any change in your side.
⚠️ Reset when an update becomes the default, so if you prefer not to remove all download versions when updating from the store, do this:
Update your code
Lastly, update all your imports in JS from:
to
Then build your code again npm run build
and copy assets once more npx cap copy
.
You should be able now to test the last auto-update system
Send your version with:
instead of
Future evolution
For now only the first public channel is in use, in the future, public will change to something related to AB test, if more than one is set.
Common problems:
- Build problem after upgrade: if you have already opened the source code of the plugin in Android studio or Xcode, sometimes the sync doesn’t remove them, that the cause of the issue. Open the native IDE and remove
capacitor-updater
by hands and donpx cap sync
this should solve.