diff options
author | Christian Hesse <mail@eworm.de> | 2019-07-24 10:49:51 +0200 |
---|---|---|
committer | Christian Hesse <mail@eworm.de> | 2019-07-24 10:49:51 +0200 |
commit | 6699545157e0ecdcdefdad0d6f133bf890612c9b (patch) | |
tree | 76b20e932324b328c0cef28ebad66e50984cb0b9 /packages-update | |
parent | 7fe0938f86a7041e78fae280b28dae852008ef1b (diff) |
packages-update: allow to downgrade on change of update channel
Diffstat (limited to 'packages-update')
-rw-r--r-- | packages-update | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/packages-update b/packages-update index 7d161c2..76bf120 100644 --- a/packages-update +++ b/packages-update @@ -30,6 +30,15 @@ / system script run $Script; } +:if (!([ /system resource get version ] ~ ($Update->"channel"))) do={ + :put "Update channel changed. Want to downgrade? [y/N]"; + :if ([ :terminal inkey timeout=60 ] = 121) do={ + :log info ("Rebooting for downgrade."); + :delay 1s; + / system package downgrade; + } +} + :log info ("Rebooting for update."); :delay 1s; / system reboot; |