summaryrefslogtreecommitdiff
path: root/updater-ng/files/uci-defaults
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2022-01-26 13:53:47 +0100
committerKarel Kočí <cynerd@email.cz>2022-01-26 13:53:47 +0100
commit7aaa211601597aee58e56d99cf8530a7ba52d80c (patch)
tree31d4278dda402272c95692cda8a5ce162951e96e /updater-ng/files/uci-defaults
parent53aaeee4bbdb41453d40563ad228ae2dccfcc7e6 (diff)
downloadopenwrt-personal-pkgs-7aaa211601597aee58e56d99cf8530a7ba52d80c.tar.gz
openwrt-personal-pkgs-7aaa211601597aee58e56d99cf8530a7ba52d80c.tar.bz2
openwrt-personal-pkgs-7aaa211601597aee58e56d99cf8530a7ba52d80c.zip
updater-ng: test update to 70.0.0
Diffstat (limited to 'updater-ng/files/uci-defaults')
-rw-r--r--updater-ng/files/uci-defaults16
1 files changed, 16 insertions, 0 deletions
diff --git a/updater-ng/files/uci-defaults b/updater-ng/files/uci-defaults
new file mode 100644
index 0000000..63fe73b
--- /dev/null
+++ b/updater-ng/files/uci-defaults
@@ -0,0 +1,16 @@
+#!/bin/sh
+set -eu
+
+# bootstrap file is created to store content of BOOTSTRAP_UPDATER_BRANCH
+# environment variable, if defined, when updater is run in out root mode (the way
+# bootstrap is performed).
+# BOOTSTRAP_UPDATER_BRANCH contains simply target branch for updater (eg. HBL or HBD).
+bootstrap="/usr/share/updater/bootstrap-updater-branch"
+
+if [ -f "$bootstrap" ]; then
+ uci -q batch <<-EOF
+ set updater.turris.branch='$(cat "$bootstrap")'
+ commit updater.turris.branch
+ EOF
+ rm -f "$bootstrap"
+fi