mkdir -p $pkg
osc -A $API api /source/$PRJ/$pkg/_link >$pkg/_link
osc -A $API api /source/$PRJ/$pkg/_meta >$pkg/_meta
- msg="$msg (updated)"
+ if grep '<build' $pkg/_meta &>/dev/null; then
+ msg="$msg (updated, with meta)"
+ else
+ rm $pkg/_meta
+ msg="$msg (updated)"
+ fi
;;
*)
+ content=$(osc -A $API api /source/$PRJ/$pkg/_meta)
+ if echo $content | grep -q '<build>' ; then
+ mkdir -p $pkg
+ echo $content >$pkg/_meta
+ msg="$msg (updated)"
+ fi
;;
esac
-
echo $msg
}