system: uci: Use config dir on uci_add and support add_/del_list
authorKristian Evensen <kristian.evensen@gmail.com>
Wed, 15 May 2019 18:56:18 +0000 (20:56 +0200)
committerPetr Štetiar <ynezz@true.cz>
Fri, 17 May 2019 19:41:43 +0000 (21:41 +0200)
commit97780e363f1bfaef9451bb16fa94a0e73a18ebe6
treead642cccd86140baf16fed836889b9f4b6cdc0fd
parent869376710d70b1e2c9f5265bc8840738794bb280
system: uci: Use config dir on uci_add and support add_/del_list

This commit makes three changes to the uci shell library:

* A check for UCI_CONFIG_DIR has been added to the command line when
adding anonymous sections. Without this change, adding anonymous
sections to configs not stored in /etc/config is not possible.

* Support for adding/removing items from lists were missing, so I have
added the functions uci_add_list() and uci_remove_list() to simplify
working with uci lists from scripts.

Signed-off-by: Kristian Evensen <kristian.evensen@gmail.com>
[added missing package version bump]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
package/system/uci/Makefile
package/system/uci/files/lib/config/uci.sh