From 1a2b02f683b7e9987031d4d600fd717e748aefc1 Mon Sep 17 00:00:00 2001 From: puretension Date: Sun, 26 May 2024 02:43:00 +0900 Subject: [PATCH] =?UTF-8?q?Test:=20CI/CD=EB=A5=BC=20=ED=86=B5=ED=95=9C=20t?= =?UTF-8?q?estflight=20=EB=B0=B0=ED=8F=AC=20=EC=9E=90=EB=8F=99=ED=99=94?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/build.yml | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8ff04d09..3aebfca8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -46,9 +46,16 @@ jobs: - name: Update bundle version run: | - VERSION_NUMBER=$(date +%Y%m%d%H%M) - /usr/libexec/PlistBuddy -c "Set :CFBundleVersion $VERSION_NUMBER" "ios/PoppinProject/Info.plist" - /usr/libexec/PlistBuddy -c "Set :CFBundleShortVersionString $VERSION_NUMBER" "ios/PoppinProject/Info.plist" + # Set the major and minor version numbers + MAJOR_VERSION=1 + MINOR_VERSION=0 + # Get the current build number + BUILD_NUMBER=$(defaults read "$(pwd)/ios/PoppinProject/Info" CFBundleVersion || echo "0") + # Increment the build number + NEW_BUILD_NUMBER=$((BUILD_NUMBER + 1)) + # Update the Info.plist with the new build number + /usr/libexec/PlistBuddy -c "Set :CFBundleShortVersionString ${MAJOR_VERSION}.${MINOR_VERSION}" "ios/PoppinProject/Info.plist" + /usr/libexec/PlistBuddy -c "Set :CFBundleVersion ${MAJOR_VERSION}.${MINOR_VERSION}.${NEW_BUILD_NUMBER}" "ios/PoppinProject/Info.plist" - name: Decode iOS secrets env: