mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-29 01:59:02 +00:00
780ccbf9f1
Allow passing a filename to change the location of the generated board.json. Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
15 lines
204 B
Bash
Executable File
15 lines
204 B
Bash
Executable File
#!/bin/sh
|
|
|
|
CFG=$1
|
|
|
|
[ -n "$CFG" ] || CFG=/etc/board.json
|
|
|
|
[ -d "/etc/board.d/" -a ! -f "$CFG" ] && {
|
|
for a in `ls /etc/board.d/*`; do
|
|
[ -x $a ] || continue;
|
|
$(. $a)
|
|
done
|
|
}
|
|
|
|
[ -f "$CFG" ] || return 1
|