sed -i ''"s/VERSION/${PACKAGE_VERSION}/g""${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec ||exit1
sed -i ''"s/DESCRIPTION/${PACKAGE_DESCRIPTION}/g""${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec ||exit1
sed -i ''"s/\.framework/\.xcframework/g""${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec ||exit1
sed -i ''"s/-framework/-xcframework/g""${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec ||exit1
sed -i ''"s/ios\.xcframeworks/ios\.frameworks/g""${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec ||exit1
sed -i ''"s/9\.3/12\.1/g""${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec ||exit1
sed -i ''"s/ffmpegkit\.xcframework\/LICENSE/ffmpegkit\.xcframework\/ios-arm64\/ffmpegkit\.framework\/LICENSE/g""${CURRENT_PACKAGE}"/"${PACKAGE_NAME}".podspec ||exit1
}
if[[$# -ne 1]];
then
echo"Usage: ios.sh <version name>"
exit1
fi
# VALIDATE VERSIONS
if[["${APPLE_FFMPEG_KIT_VERSION}" !="$1"]];then
echo"Error: version mismatch. v$1 requested but v${APPLE_FFMPEG_KIT_VERSION} found. Please perform the following updates and try again."
echo"1. Update docs"
echo"2. Update gradle files under the tools/release/android folder"
echo"3. Update the versions in tools/release/common.sh"
echo"4. Update podspec links"
echo"5. Update ffmpegkit.h versions for both android and apple"