fix: expandPlatforms need use , split

pull/217/head
zijiren233 7 months ago
parent e0e0af8fa2
commit 43dae84aad

@ -802,12 +802,12 @@ function expandPlatforms() {
elif [[ "${platform}" == *\** ]]; then elif [[ "${platform}" == *\** ]]; then
local tmp_var="" local tmp_var=""
for tmp_var in ${CURRENT_ALLOWED_PLATFORMS//,/ }; do for tmp_var in ${CURRENT_ALLOWED_PLATFORMS//,/ }; do
[[ "${tmp_var}" == ${platform} ]] && expanded_platforms="${expanded_platforms} ${tmp_var}" [[ "${tmp_var}" == ${platform} ]] && expanded_platforms="${expanded_platforms},${tmp_var}"
done done
elif [[ "${platform}" != */* ]]; then elif [[ "${platform}" != */* ]]; then
expanded_platforms="${expanded_platforms} $(expandPlatforms "${platform}/*")" expanded_platforms="${expanded_platforms},$(expandPlatforms "${platform}/*")"
else else
expanded_platforms="${expanded_platforms} ${platform}" expanded_platforms="${expanded_platforms},${platform}"
fi fi
done done
removeDuplicatePlatforms "${expanded_platforms}" removeDuplicatePlatforms "${expanded_platforms}"
@ -903,6 +903,11 @@ while [[ $# -gt 0 ]]; do
echo "${CURRENT_ALLOWED_PLATFORMS}" echo "${CURRENT_ALLOWED_PLATFORMS}"
exit 0 exit 0
;; ;;
--show-all-platforms=*)
initPlatforms
echo "$(expandPlatforms "${1#*=}")"
exit 0
;;
--github-proxy-mirror=*) --github-proxy-mirror=*)
GH_PROXY="${1#*=}" GH_PROXY="${1#*=}"
;; ;;

Loading…
Cancel
Save