Read version from build settings in build script
This commit is contained in:
@@ -23,7 +23,15 @@ if [[ ! -d "$APP_PATH" ]]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
ZIP_NAME="iKeyMon-$(/usr/libexec/PlistBuddy -c 'Print :CFBundleShortVersionString' \"$APP_PATH/Contents/Info.plist\").zip"
|
VERSION=$(xcodebuild \
|
||||||
|
-project "$ROOT_DIR/$PROJECT" \
|
||||||
|
-scheme "$SCHEME" \
|
||||||
|
-configuration Release \
|
||||||
|
-showBuildSettings | awk '/MARKETING_VERSION/ {print $3; exit}')
|
||||||
|
if [[ -z "$VERSION" ]]; then
|
||||||
|
VERSION="dev"
|
||||||
|
fi
|
||||||
|
ZIP_NAME="iKeyMon-${VERSION}.zip"
|
||||||
pushd "$(dirname "$APP_PATH")" >/dev/null
|
pushd "$(dirname "$APP_PATH")" >/dev/null
|
||||||
zip -r "$ARTIFACTS_DIR/$ZIP_NAME" "$(basename "$APP_PATH")"
|
zip -r "$ARTIFACTS_DIR/$ZIP_NAME" "$(basename "$APP_PATH")"
|
||||||
popd >/dev/null
|
popd >/dev/null
|
||||||
|
|||||||
Reference in New Issue
Block a user