Commit Graph

9 Commits

Author SHA1 Message Date
Matthias Schiffer
53cf8796c7
gluon-autoupdater: revert to default branch when configured branch is invalid
An invalid branch may be set for various reasons:

- Previous firmware had an invalid default branch
- Branch list has changed and old UCI branch config was removed by a
  site-specific upgrade script
- Manual UCI configuration
2022-05-27 12:00:32 +02:00
Matthias Schiffer
2c65f0834b
gluon-autoupdater: factor out default_branch() function
Make the code clearer and prepare for invalid branch fixup.
2022-05-27 12:00:32 +02:00
Matthias Schiffer
d82ffb4f81
gluon-autoupdater: make site.conf branch setting optional
Default to the alphabetically smallest branch if none is set in
site.conf.

Also prevent enabling the autoupdater when no branches exist.
2020-08-15 16:36:27 +02:00
Matthias Schiffer
ee53357580
gluon-autoupdater: split CONFIG_GLUON_BRANCH into two separate options
The new options are CONFIG_GLUON_AUTOUPDATER_BRANCH and
CONFIG_GLUON_AUTOUPDATER_ENABLED and allow to control the default branch
and default enable status separately.

The `or ''` fallback in targets/generic is removed, as GLUON_ENV will
set all variables in GLUON_VARS, making previously non-existing
variables exist with an empty value.
2020-08-15 16:36:27 +02:00
Matthias Schiffer
18feb29b29
gluon-autoupdater: don't reference old autoupdater util library
Fixes #1310
2018-01-17 01:06:15 +01:00
Matthias Schiffer
ee6afaced9
treewide: use new gluon.site Lua library
Some files have received some additional refactoring.
2017-08-11 22:07:34 +02:00
Matthias Schiffer
43f32e3c3b
gluon-autoupdater: fix incomplete comment in upgrade script
Fixes #1043
2017-02-16 08:46:41 +01:00
Matthias Schiffer
6cf03bab37
treewide: replace normal uses of luci.model.uci with simple-uci to reduce LuCI dependencies
We also make use of the boolean support of simple-uci to make scripts
clearer.
2017-02-10 02:10:01 +01:00
Jan-Tarek Butt
1c1f490527
Minify all Lua code 2016-07-10 20:14:25 +02:00