All pastes #277433 Raw Edit

Mine

public text v1 · immutable
·published 2006-12-13 05:15 UTC
rendered paste body
. /etc/functions.sh
. /lib/config/uci.sh

# create config file if it doesn't exist (first run)
[ ! -f "/etc/config/ucitest" ] && {
        uci_add "ucitest" "testtype" "testopt"
}

uci_load "ucitest"
uci_set "ucitest" "testopt" "testvar" "test"
uci_commit "ucitest"

# error shown:
# mv: unable to rename `/tmp/.uci/ucitest.new': No such file or directory