tools/refresh.sh: Add option to refresh custom board
This patch modify the script to update only the boards configs of an specific chip or only the boards of an specific architecture. Examples: refresh.sh add custom board verify custom board: $ ./tools/refresh.sh --silent ../../xxx/configs/ap $ ./tools/refresh.sh --silent /yyy/xxx/configs/ap $ ./tools/refresh.sh --silent yyy/xxx/configs/ap Signed-off-by: dengwenqi <dengwenqi@xiaomi.com>
This commit is contained in:
parent
00128ff2fe
commit
b435005415
@ -18,6 +18,7 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
WD=`test -d ${0%/*} && cd ${0%/*}; pwd`
|
WD=`test -d ${0%/*} && cd ${0%/*}; pwd`
|
||||||
|
CWD=`pwd`
|
||||||
|
|
||||||
USAGE="USAGE: $0 [options] <board>:<config>+"
|
USAGE="USAGE: $0 [options] <board>:<config>+"
|
||||||
ADVICE="Try '$0 --help' for more information"
|
ADVICE="Try '$0 --help' for more information"
|
||||||
@ -150,7 +151,18 @@ for CONFIG in ${CONFIGS}; do
|
|||||||
BOARDSUBDIR=`echo ${CONFIG} | cut -d':' -f1`
|
BOARDSUBDIR=`echo ${CONFIG} | cut -d':' -f1`
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
BOARDDIR=${CONFIG}
|
||||||
|
if [ ! -d $BOARDDIR ]; then
|
||||||
|
BOARDDIR="${CWD}/${BOARDDIR}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -d $BOARDDIR ]; then
|
||||||
|
CONFIGSUBDIR=`basename ${CONFIG}`
|
||||||
|
BOARDDIR=$(dirname `dirname ${BOARDDIR}`)
|
||||||
|
else
|
||||||
BOARDDIR=boards/*/*/$BOARDSUBDIR
|
BOARDDIR=boards/*/*/$BOARDSUBDIR
|
||||||
|
fi
|
||||||
|
|
||||||
SCRIPTSDIR=$BOARDDIR/scripts
|
SCRIPTSDIR=$BOARDDIR/scripts
|
||||||
MAKEDEFS1=$SCRIPTSDIR/Make.defs
|
MAKEDEFS1=$SCRIPTSDIR/Make.defs
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user