diff --git a/.github/project_workflows/deploy_production_firebase.yml b/.github/project_workflows/deploy_production_firebase.yml index 3e3d989e..d2b95cff 100644 --- a/.github/project_workflows/deploy_production_firebase.yml +++ b/.github/project_workflows/deploy_production_firebase.yml @@ -24,6 +24,12 @@ jobs: with: fetch-depth: 0 + - name: Create Release Note + run: | + echo "RELEASE_NOTES<> $GITHUB_ENV + echo "$(git log -1 | grep -o "\[.*")" >> $GITHUB_ENV + echo "EOF" >> $GITHUB_ENV + - name: Run SwiftLint uses: docker://norionomura/swiftlint:0.53.0_swift-5.7 with: diff --git a/.github/project_workflows/deploy_staging_firebase.yml b/.github/project_workflows/deploy_staging_firebase.yml index 82619532..4543ad42 100644 --- a/.github/project_workflows/deploy_staging_firebase.yml +++ b/.github/project_workflows/deploy_staging_firebase.yml @@ -38,6 +38,12 @@ jobs: with: fetch-depth: 0 + - name: Create Release Note + run: | + echo "RELEASE_NOTES<> $GITHUB_ENV + echo "$(git log -1 | grep -o "\[.*")" >> $GITHUB_ENV + echo "EOF" >> $GITHUB_ENV + - name: Install SSH key uses: webfactory/ssh-agent@v0.7.0 with: diff --git a/.github/workflows/test_upload_build_to_firebase.yml b/.github/workflows/test_upload_build_to_firebase.yml index 8aff8251..397dc1bc 100644 --- a/.github/workflows/test_upload_build_to_firebase.yml +++ b/.github/workflows/test_upload_build_to_firebase.yml @@ -24,6 +24,12 @@ jobs: with: fetch-depth: 0 + - name: Create Release Note + run: | + echo "RELEASE_NOTES<> $GITHUB_ENV + echo "$(git log -1 | grep -o "\[.*")" >> $GITHUB_ENV + echo "EOF" >> $GITHUB_ENV + - name: Install SSH key uses: webfactory/ssh-agent@v0.7.0 with: diff --git a/fastlane/Constants/Constant.swift b/fastlane/Constants/Constant.swift index 155852e1..8b019e5d 100644 --- a/fastlane/Constants/Constant.swift +++ b/fastlane/Constants/Constant.swift @@ -65,6 +65,10 @@ enum Constant { return .unknown } + static var releaseNote: String { + EnvironmentParser.string(key: "RELEASE_NOTES") + } + // MARK: - Project static let stagingBundleId = "{BUNDLE_ID_STAGING}" diff --git a/fastlane/Fastfile.swift b/fastlane/Fastfile.swift index d8e1f09d..aa4634a9 100644 --- a/fastlane/Fastfile.swift +++ b/fastlane/Fastfile.swift @@ -85,7 +85,7 @@ class Fastfile: LaneFile { buildAdHocStagingLane() // TODO: - Make release notes - Distribution.uploadToFirebase(environment: .staging, releaseNotes: "") + Distribution.uploadToFirebase(environment: .staging, releaseNotes: Constant.releaseNote) Symbol.uploadToCrashlytics(environment: .staging) @@ -101,7 +101,7 @@ class Fastfile: LaneFile { buildAdHocProductionLane() // TODO: - Make release notes - Distribution.uploadToFirebase(environment: .production, releaseNotes: "") + Distribution.uploadToFirebase(environment: .production, releaseNotes: Constant.releaseNote) Symbol.uploadToCrashlytics(environment: .production) @@ -137,7 +137,7 @@ class Fastfile: LaneFile { buildAppStoreLane() AppStoreAuthentication.connectAPIKey() - Distribution.uploadToTestFlight() + Distribution.uploadToTestFlight(changeLog: Constant.releaseNote) Symbol.uploadToCrashlytics(environment: .production)