How to reinstall a snap package?
I would like to reinstall a snap package due to a missing library file (removing and installing the snap again fixed this problem on another system).
How can I avoid the uninstall step (thus preserving my settings) and install again?
Solution 1:
Unfortunately a command or option to reinstall a snap similar to apt install --reinstall
does not exist. So removing and then installing the snap again is the only way.
But the settings of the snap will be saved in a snapshot while removing the snap unless you use the --purge
-option, so just run snap remove snapname
but not snap remove --purge snapname
.
Check the snapshot with snap saved
to see it's ID.
After installing the snap again you can restore the snapshot with snap restore ID
and your settings are back.