mirror of
https://github.com/openwrt/openwrt.git
synced 2025-01-21 20:08:24 +00:00
uci: add missing 'option' support to uci_rename()
When using the uci.sh wrapper, allow parameters to match those supported by the uci binary i.e. "uci rename <config>.<section>[.<option>]=<name>". Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
This commit is contained in:
parent
7fc94b2a25
commit
cf4a37a581
@ -118,9 +118,10 @@ uci_add() {
|
||||
uci_rename() {
|
||||
local PACKAGE="$1"
|
||||
local CONFIG="$2"
|
||||
local VALUE="$3"
|
||||
local OPTION="$3"
|
||||
local VALUE="$4"
|
||||
|
||||
/sbin/uci ${UCI_CONFIG_DIR:+-c $UCI_CONFIG_DIR} rename "$PACKAGE.$CONFIG=$VALUE"
|
||||
/sbin/uci ${UCI_CONFIG_DIR:+-c $UCI_CONFIG_DIR} rename "$PACKAGE.$CONFIG${VALUE:+.$OPTION}=${VALUE:-$OPTION}"
|
||||
}
|
||||
|
||||
uci_remove() {
|
||||
|
Loading…
Reference in New Issue
Block a user