diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2015-11-30 10:17:05 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2015-11-30 10:17:05 +0000 |
commit | 381b6db306fc9167bcd49477a10bf1c91498edf9 (patch) | |
tree | e77ef183475e548c626dd65216fbdb0279e733ca /package/base-files/files | |
parent | 881a78a643e0c6b831548713ebef9dd041763846 (diff) | |
download | master-187ad058-381b6db306fc9167bcd49477a10bf1c91498edf9.tar.gz master-187ad058-381b6db306fc9167bcd49477a10bf1c91498edf9.tar.bz2 master-187ad058-381b6db306fc9167bcd49477a10bf1c91498edf9.zip |
base-files: uci-defaults-new: add board id and name helpers
Add ucidef_set_board_id() and ucidef_set_model_name() procedures to store
model information in the board.json file.
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@47671 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/base-files/files')
-rwxr-xr-x | package/base-files/files/lib/functions/uci-defaults-new.sh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/package/base-files/files/lib/functions/uci-defaults-new.sh b/package/base-files/files/lib/functions/uci-defaults-new.sh index e79ec99f53..3fe89838e4 100755 --- a/package/base-files/files/lib/functions/uci-defaults-new.sh +++ b/package/base-files/files/lib/functions/uci-defaults-new.sh @@ -38,6 +38,18 @@ _ucidef_set_interface() { json_select .. } +ucidef_set_board_id() { + json_select_object model + json_add_string id "$1" + json_select .. +} + +ucidef_set_model_name() { + json_select_object model + json_add_string name "$1" + json_select .. +} + ucidef_set_interface_loopback() { # stub |