Make sure we dont lose the compat_version (#1697)

This commit is contained in:
Tim Wilkinson 2024-11-16 20:51:07 -08:00 committed by GitHub
parent 1b2b481958
commit 7811763ecc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 8 deletions

View File

@ -1,8 +0,0 @@
#! /bin/sh
VER=$(jsonfilter -e '@.system.compat_version' < /etc/board.json)
if [ "${VER}" != "" ]; then
uci -c /etc/config.mesh -q set setup.globals.compat_version=${VER}
uci -c /etc/config.mesh commit setup
uci -q set system.@system[0].compat_version=${VER}
uci -q commit system
fi

View File

@ -175,6 +175,12 @@ if wifi_enable == 0 then
cfg.wifi_enable = wifi_enable
end
-- Make sure compat version is correct
local system = aredn.hardware.get_board().system
if system and system.compat_version then
cfg.compat_version = system.compat_version
end
-- Radio
if aredn.hardware.get_radio_count() > 0 and cfg.wifi_intf == "" then
local wifi_intf = "wlan0"