Skip to content

Commit

Permalink
[493] Generate release notes when uploading builds to Firebase/TestFl…
Browse files Browse the repository at this point in the history
…ight
  • Loading branch information
markgravity committed Dec 17, 2024
1 parent cdef603 commit de8e6d3
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 3 deletions.
6 changes: 6 additions & 0 deletions .github/project_workflows/deploy_production_firebase.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ jobs:
with:
fetch-depth: 0

- name: Create Release Note
run: |
echo "RELEASE_NOTES<<EOF" >> $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:
Expand Down
6 changes: 6 additions & 0 deletions .github/project_workflows/deploy_staging_firebase.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,12 @@ jobs:
with:
fetch-depth: 0

- name: Create Release Note
run: |
echo "RELEASE_NOTES<<EOF" >> $GITHUB_ENV
echo "$(git log -1 | grep -o "\[.*")" >> $GITHUB_ENV
echo "EOF" >> $GITHUB_ENV
- name: Install SSH key
uses: webfactory/[email protected]
with:
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/test_upload_build_to_firebase.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ jobs:
with:
fetch-depth: 0

- name: Create Release Note
run: |
echo "RELEASE_NOTES<<EOF" >> $GITHUB_ENV
echo "$(git log -1 | grep -o "\[.*")" >> $GITHUB_ENV
echo "EOF" >> $GITHUB_ENV
- name: Install SSH key
uses: webfactory/[email protected]
with:
Expand Down
4 changes: 4 additions & 0 deletions fastlane/Constants/Constant.swift
Original file line number Diff line number Diff line change
Expand Up @@ -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}"
Expand Down
6 changes: 3 additions & 3 deletions fastlane/Fastfile.swift
Original file line number Diff line number Diff line change
Expand Up @@ -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)

Expand All @@ -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)

Expand Down Expand Up @@ -137,7 +137,7 @@ class Fastfile: LaneFile {
buildAppStoreLane()

AppStoreAuthentication.connectAPIKey()
Distribution.uploadToTestFlight()
Distribution.uploadToTestFlight(changeLog: Constant.releaseNote)

Symbol.uploadToCrashlytics(environment: .production)

Expand Down

0 comments on commit de8e6d3

Please sign in to comment.