compat-wireless: skip directory if patches directory is empty
authorLuis R. Rodriguez <lrodriguez@atheros.com>
Mon, 7 Feb 2011 16:56:15 +0000 (08:56 -0800)
committerLuis R. Rodriguez <lrodriguez@atheros.com>
Mon, 7 Feb 2011 16:57:05 +0000 (08:57 -0800)
Instead of getting a nag, just skip the directory if its empty.

Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
scripts/admin-update.sh

index f65ea854d67b89b1e4632fc6daec2b8fe0276a88..6fe49ce0682e5f9f5c8d4a53c57a530b63dbf7d1 100755 (executable)
@@ -531,6 +531,10 @@ for dir in $EXTRA_PATCHES; do
 done
 
 for dir in $EXTRA_PATCHES; do
+       if [[ ! -d $dir ]]; then
+               echo -e "${RED}Patches: $dir empty, skipping...${NORMAL}\n"
+               continue
+       fi
        if [[ $LAST_ELEM = $dir && "$REFRESH" = y ]]; then
                patchRefresh $dir
        fi