diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4fa736b..be94bad 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -45,9 +45,12 @@ jobs: - name: Update Build Number env: TAG_NAME: ${{ github.ref }} + RUN_ID: ${{ github.run_id }} run: | export CLEAN_TAG=$(echo $TAG_NAME | sed -e 's/refs\/tags\/v//') - sed -i '' -e "s/CI_VERSION = 0.0.0/CI_VERSION = $CLEAN_TAG/g" Config/Config.xcconfig + sed -i '' -e "s/GITHUB_CI_VERSION/$CLEAN_TAG/g" Config/Config.xcconfig + sed -i '' -e "s/GITHUB_BUILD_NUMBER/1.$RUN_ID/g" Config/Config.xcconfig + sed -i '' -e "s/GITHUB_BUILD_URL/https:\/\/github.com\/maxgoedjen\/secretive\/actions\/runs\/$RUN_ID/g" Secretive/Credits.rtf - name: Build run: xcrun xcodebuild -project Secretive.xcodeproj -scheme Secretive -configuration Release -archivePath Archive.xcarchive archive - name: Create ZIPs diff --git a/Config/Config.xcconfig b/Config/Config.xcconfig index b265fbc..9c18c35 100644 --- a/Config/Config.xcconfig +++ b/Config/Config.xcconfig @@ -1 +1,2 @@ -CI_VERSION = 0.0.0 \ No newline at end of file +CI_VERSION = GITHUB_CI_VERSION +CI_BUILD_NUMBER = GITHUB_BUILD_NUMBER