running "./scripts/admin-refresh.sh -n -p -c refresh" failed because the patches were applied but Signed-off-by: Hauke Mehrtens <hauke@xxxxxxxxxx> --- scripts/admin-update.sh | 14 ++++++++------ 1 files changed, 8 insertions(+), 6 deletions(-) diff --git a/scripts/admin-update.sh b/scripts/admin-update.sh index 99ab6c3..36cce31 100755 --- a/scripts/admin-update.sh +++ b/scripts/admin-update.sh @@ -391,12 +391,6 @@ patchRefresh() { rm -rf patches.orig .pc $1/series } -if [[ "$REFRESH" = "y" ]]; then - for dir in $EXTRA_PATCHES; do - patchRefresh $dir - done -fi - ORIG_CODE=$(find ./ -type f -name \*.[ch] | egrep -v "^./compat/|include/linux/compat" | xargs wc -l | tail -1 | awk '{print $1}') @@ -404,6 +398,14 @@ printf "\n${CYAN}compat-wireless code metrics${NORMAL}\n\n" > $CODE_METRICS printf "${PURPLE}%10s${NORMAL} - Total upstream code being pulled\n" $ORIG_CODE >> $CODE_METRICS for dir in $EXTRA_PATCHES; do + LAST_ELEM=$dir +done + +for dir in $EXTRA_PATCHES; do + if [[ $LAST_ELEM = $dir && "$REFRESH" = y ]]; then + patchRefresh $dir + fi + FOUND=$(find $dir/ -name \*.patch | wc -l) if [ $FOUND -eq 0 ]; then continue -- 1.7.0.4 -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html