parse json first, since different versions have different naming schemes and we need to parse that part afterwards

This commit is contained in:
Gareth J. Greenaway 2023-04-14 05:46:31 -07:00
parent d0032c7495
commit efbd416607
No known key found for this signature in database
GPG key ID: 10B62F8A7CAD7A41

View file

@ -8479,6 +8479,9 @@ __macosx_get_packagesite_onedir() {
__PY_VERSION_REPO="py3"
fi
if [ "$(echo "$_ONEDIR_REV" | grep -E '^(latest)$')" != "" ]; then
_ONEDIR_REV=$(__parse_repo_json_python)
fi
if [ "$(echo "$_ONEDIR_REV" | grep -E '^(3005)$')" != "" ]; then
PKG="salt-${_ONEDIR_REV}-macos-${DARWIN_ARCH}.pkg"
else
@ -8487,9 +8490,6 @@ __macosx_get_packagesite_onedir() {
else
UNSIGNED=""
fi
if [ "$(echo "$_ONEDIR_REV" | grep -E '^(latest)$')" != "" ]; then
_ONEDIR_REV=$(__parse_repo_json_python)
fi
PKG="salt-${_ONEDIR_REV}-${__PY_VERSION_REPO}-${DARWIN_ARCH}${UNSIGNED}.pkg"
fi
SALTPKGCONFURL="https://${_REPO_URL}/${_ONEDIR_DIR}/${__PY_VERSION_REPO}/macos/${_ONEDIR_REV}/${PKG}"