From e14b9cf7de582b113f48f11a7a070d04bb7fc3b0 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 19 Mar 2023 10:30:22 +0200 Subject: [PATCH 01/44] release to QA --- .github/bash_scripts/pre_release.sh | 19 ++++++++++++++ .github/bash_scripts/release.sh | 15 +++++++++++ .github/workflows/prepare-for-QA-release.yml | 26 +++++++++++++++++++ .github/workflows/release-QA-workflow.yml | 15 +++++++++++ .../{test.yml => unit-tests-workflow.yml} | 2 ++ 5 files changed, 77 insertions(+) create mode 100644 .github/bash_scripts/pre_release.sh create mode 100644 .github/bash_scripts/release.sh create mode 100644 .github/workflows/prepare-for-QA-release.yml create mode 100644 .github/workflows/release-QA-workflow.yml rename .github/workflows/{test.yml => unit-tests-workflow.yml} (95%) diff --git a/.github/bash_scripts/pre_release.sh b/.github/bash_scripts/pre_release.sh new file mode 100644 index 0000000..1b07bf6 --- /dev/null +++ b/.github/bash_scripts/pre_release.sh @@ -0,0 +1,19 @@ +#!/bin/bash + +releaseversion=$1 + +sed -r -i '' "s/(.*)(af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$releaseversion\'/g" app/build.gradle + +sed -r -i '' "s/(.*)(af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$releaseversion\'/g" segmenttestapp/build.gradle + +version_code=$(grep -E 'VERSION_CODE=([0-9]+)' gradle.properties | grep -o '[0-9]\+') +version_code=$((version_code+1)) +sed -r -i '' "s/VERSION_CODE=([0-9]+)/VERSION_CODE=$version_code/g" gradle.properties + +sed -r -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+)/VERSION_NAME=$releaseversion/g" gradle.properties + +sed -r -i '' "s/(Built with AppsFlyer Android SDK.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$releaseversion\3/g" Readme.md +sed -r -i '' "s/(.*appsflyer:segment-android-integration:)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$releaseversion\3/g" Readme.md +sed -r -i '' "s/(.*Maven Central.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$releaseversion\3$releaseversion\5/g" Readme.md + +touch "releasenotes.$releaseversion" diff --git a/.github/bash_scripts/release.sh b/.github/bash_scripts/release.sh new file mode 100644 index 0000000..f941ada --- /dev/null +++ b/.github/bash_scripts/release.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +releaseversion=$1 + +sed -r -i '' "s/version_release = \'[0-9]+\.[0-9]+\.[0-9]+\'/version_release = \'$releaseversion\'/g" segment-appsflyer-ios.podspec + +sed -r -i '' "s/(.*pod \'segment-appsflyer-ios\')(.*)/\1,\'$releaseversion\'/g" examples/SwiftPodsSample/Podfile +sed -r -i '' "s/(.*pod \'segment-appsflyer-ios\')(.*)/\1,\'$releaseversion\'/g" examples/ObjcPodsSample/Podfile + +sed -i '' 's/^/* /' "releasenotes.$releaseversion" +NEW_VERSION_RELEASE_NOTES=$(cat "releasenotes.$releaseversion") +NEW_VERSION_SECTION="### $releaseversion\n* Updated iOS SDK to v$releaseversion\n$NEW_VERSION_RELEASE_NOTES\n\n" +echo -e "$NEW_VERSION_SECTION$(cat RELEASENOTES.md)" > RELEASENOTES.md + +rm -r "releasenotes.$releaseversion" \ No newline at end of file diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml new file mode 100644 index 0000000..d3de42a --- /dev/null +++ b/.github/workflows/prepare-for-QA-release.yml @@ -0,0 +1,26 @@ +name: pre-release + +on: + workflow_call: + +jobs: + Change-HardCoded-Version: + name: Pre Release + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Determine release tag and release branch + run: | + TAG=$(echo "${{github.ref_name}}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') + echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV + - name: run script + run: bash .github/bash_scripts/pre_release.sh ${{env.PLUGIN_VERSION}} + - name: Commit changes + uses: EndBug/add-and-commit@v9 + with: + author_name: Moris Gateno + author_email: moris.gateno@appsflyer.com + message: 'Commited from github action - prepaing the repo for QA locally.' + add: '.' + diff --git a/.github/workflows/release-QA-workflow.yml b/.github/workflows/release-QA-workflow.yml new file mode 100644 index 0000000..d5c1738 --- /dev/null +++ b/.github/workflows/release-QA-workflow.yml @@ -0,0 +1,15 @@ + +name: Release plugin to QA + +on: + push: + branches: + - releases/[0-9]+.x.x/[0-9]+.[0-9]+.x/[0-9]+.[0-9]+.[0-9]+-rc[0-9]+ + +jobs: + Run-Unit-Tests: + uses: ./.github/workflows/unit-tests-workflow.yml + + Deploy-Locally-To-QA: + needs: [Run-Unit-Tests] + uses: ./.github/workflows/prepare-for-QA-release.yml diff --git a/.github/workflows/test.yml b/.github/workflows/unit-tests-workflow.yml similarity index 95% rename from .github/workflows/test.yml rename to .github/workflows/unit-tests-workflow.yml index 977ded4..45e6d92 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/unit-tests-workflow.yml @@ -3,7 +3,9 @@ on: push: branches-ignore: - 'main' + - 'master' - 'releases/**' + workflow_call: jobs: Tests: runs-on: ubuntu-latest From cce8b6d6fb905bb73b1c435522cc38e19fcb0503 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 19 Mar 2023 10:38:46 +0200 Subject: [PATCH 02/44] script change --- .github/bash_scripts/pre_release.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/bash_scripts/pre_release.sh b/.github/bash_scripts/pre_release.sh index 1b07bf6..399f0e4 100644 --- a/.github/bash_scripts/pre_release.sh +++ b/.github/bash_scripts/pre_release.sh @@ -2,9 +2,9 @@ releaseversion=$1 -sed -r -i '' "s/(.*)(af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$releaseversion\'/g" app/build.gradle +sed -r -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$releaseversion\'/g" app/build.gradle -sed -r -i '' "s/(.*)(af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$releaseversion\'/g" segmenttestapp/build.gradle +sed -r -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$releaseversion\'/g" segmenttestapp/build.gradle version_code=$(grep -E 'VERSION_CODE=([0-9]+)' gradle.properties | grep -o '[0-9]\+') version_code=$((version_code+1)) From 9ff352c42b8734d6408d917af4dded4f47ee8d7b Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Wed, 22 Mar 2023 08:20:56 +0200 Subject: [PATCH 03/44] Readme file change --- RELEASENOTES.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/RELEASENOTES.md b/RELEASENOTES.md index 3add3e3..dcb8e74 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -1,5 +1,3 @@ -# Release Notes - ### 6.10.1 * Update Android SDK to v6.10.1 * Added unit tests. From 24a9715765b12329c486a5754e46b436c2b062e1 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Wed, 22 Mar 2023 08:27:34 +0200 Subject: [PATCH 04/44] added a check if notes were added to the repo --- .github/workflows/release-QA-workflow.yml | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release-QA-workflow.yml b/.github/workflows/release-QA-workflow.yml index d5c1738..9daf908 100644 --- a/.github/workflows/release-QA-workflow.yml +++ b/.github/workflows/release-QA-workflow.yml @@ -7,9 +7,25 @@ on: - releases/[0-9]+.x.x/[0-9]+.[0-9]+.x/[0-9]+.[0-9]+.[0-9]+-rc[0-9]+ jobs: + Check-If-ReleaseNotes-Pushed: + runs-on: ubuntu-latest + outputs: + answer: ${{ steps.filter.outputs.releasenotesfile }} + steps: + - uses: actions/checkout@v2 + - uses: dorny/paths-filter@v2 + id: filter + with: + filters: | + releasenotesfile: + - 'releasenotes.**' + Run-Unit-Tests: + needs: Check-If-ReleaseNotes-Pushed + if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' uses: ./.github/workflows/unit-tests-workflow.yml Deploy-Locally-To-QA: - needs: [Run-Unit-Tests] + needs: [Run-Unit-Tests,Check-If-ReleaseNotes-Pushed] + if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' uses: ./.github/workflows/prepare-for-QA-release.yml From 7c4f64faef478fedc9c9a46771513e9f2da15101 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Wed, 22 Mar 2023 09:17:21 +0200 Subject: [PATCH 05/44] yaml files --- .github/bash_scripts/pre_release.sh | 16 ++--- .../prepare-for-release-workflow.yml | 34 ++++++++++ .../workflows/release-production-workflow.yml | 62 +++++++++++++++++++ 3 files changed, 104 insertions(+), 8 deletions(-) create mode 100644 .github/workflows/prepare-for-release-workflow.yml create mode 100644 .github/workflows/release-production-workflow.yml diff --git a/.github/bash_scripts/pre_release.sh b/.github/bash_scripts/pre_release.sh index 399f0e4..0c1ea46 100644 --- a/.github/bash_scripts/pre_release.sh +++ b/.github/bash_scripts/pre_release.sh @@ -1,19 +1,19 @@ #!/bin/bash -releaseversion=$1 +appsflyerversion=$1 -sed -r -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$releaseversion\'/g" app/build.gradle +sed -r -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$appsflyerversion\'/g" app/build.gradle -sed -r -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$releaseversion\'/g" segmenttestapp/build.gradle +sed -r -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$appsflyerversion\'/g" segmenttestapp/build.gradle version_code=$(grep -E 'VERSION_CODE=([0-9]+)' gradle.properties | grep -o '[0-9]\+') version_code=$((version_code+1)) sed -r -i '' "s/VERSION_CODE=([0-9]+)/VERSION_CODE=$version_code/g" gradle.properties -sed -r -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+)/VERSION_NAME=$releaseversion/g" gradle.properties +sed -r -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+)/VERSION_NAME=$appsflyerversion/g" gradle.properties -sed -r -i '' "s/(Built with AppsFlyer Android SDK.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$releaseversion\3/g" Readme.md -sed -r -i '' "s/(.*appsflyer:segment-android-integration:)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$releaseversion\3/g" Readme.md -sed -r -i '' "s/(.*Maven Central.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$releaseversion\3$releaseversion\5/g" Readme.md +sed -r -i '' "s/(Built with AppsFlyer Android SDK.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md +sed -r -i '' "s/(.*appsflyer:segment-android-integration:)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md +sed -r -i '' "s/(.*Maven Central.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3$appsflyerversion\5/g" Readme.md -touch "releasenotes.$releaseversion" +touch "releasenotes.$appsflyerversion" diff --git a/.github/workflows/prepare-for-release-workflow.yml b/.github/workflows/prepare-for-release-workflow.yml new file mode 100644 index 0000000..9aa1a17 --- /dev/null +++ b/.github/workflows/prepare-for-release-workflow.yml @@ -0,0 +1,34 @@ +# name: Prepare plugin for production + +# on: +# pull_request: +# types: +# - opened +# branches: +# # - 'master' +# - 'dev/add-release-workflow' + +# jobs: +# Prepare-Plugin-For-Production: +# if: startsWith(github.head_ref, 'releases/') +# name: Prepare for production after testing the plugin +# runs-on: ubuntu-latest +# steps: +# - name: Checkout +# uses: actions/checkout@v3 +# - name: PR branch check +# uses: mdecoleman/pr-branch-name@1.2.0 +# id: vars +# with: +# repo-token: ${{ secrets.CI_GITHUB_TOKEN }} +# - name: Determine release tag and release branch +# run: | +# TAG=$(echo "${{ steps.vars.outputs.branch }}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') +# echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV +# - name: run script +# run: bash .github/bash_scripts/release.sh ${{env.PLUGIN_VERSION}} +# - name: Commit and Push +# run : | +# git add . +# git commit -m"Commited from github action - prepaing the repo for production." +# git push origin HEAD:${{ steps.vars.outputs.branch }} --force \ No newline at end of file diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml new file mode 100644 index 0000000..c0c098d --- /dev/null +++ b/.github/workflows/release-production-workflow.yml @@ -0,0 +1,62 @@ +name: Release plugin to production + +on: + pull_request: + types: + - closed + branches: + # - 'master' + - 'dev/add-release-workflow' + +jobs: + Deploy-To-Production: + if: github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/') + runs-on: macos-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: PR branch check + uses: mdecoleman/pr-branch-name@1.2.0 + id: vars + with: + repo-token: ${{ secrets.CI_GITHUB_TOKEN }} + - name: Determine release tag and release branch + run: | + TAG=$(echo "${{ steps.vars.outputs.branch }}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') + echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV + echo "RELEASE_BRANCH_NAME=${{ steps.vars.outputs.branch }}" >> $GITHUB_ENV + echo "push new release >> $TAG" + # - name: Create release and tag + # env: + # TAG: ${{env.PLUGIN_VERSION}} + # uses: "actions/github-script@v5" + # with: + # script: | + # try { + # await github.rest.repos.createRelease({ + # draft: false, + # generate_release_notes: false, + # name: process.env.TAG, + # owner: context.repo.owner, + # prerelease: false, + # repo: context.repo.repo, + # tag_name: process.env.TAG + # }); + # } catch (error) { + # core.setFailed(error.message); + # } + - name: Install Cocoapods + run: gem install cocoapods + # - name: Push to COCOAPODS + # uses: michaelhenry/deploy-to-cocoapods-github-action@1.0.10 + # env: + # COCOAPODS_TRUNK_TOKEN: ${{ secrets.CI_COCOAPODS_TOKEN }} + - name: Notify with SLack + uses: slackapi/slack-github-action@v1.23.0 + with: + payload: | + { + "appsflyer_version": "${{env.PLUGIN_VERSION}}" + } + env: + SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} From e8e9653b839be4a5f83c9ab82373285eac39a254 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Wed, 22 Mar 2023 15:32:04 +0200 Subject: [PATCH 06/44] added release steps(yml files) --- .github/bash_scripts/release.sh | 7 +- .../prepare-for-release-workflow.yml | 64 ++++++------- .../workflows/release-production-workflow.yml | 90 ++++++++++++------- 3 files changed, 91 insertions(+), 70 deletions(-) diff --git a/.github/bash_scripts/release.sh b/.github/bash_scripts/release.sh index f941ada..f84d7af 100644 --- a/.github/bash_scripts/release.sh +++ b/.github/bash_scripts/release.sh @@ -2,14 +2,9 @@ releaseversion=$1 -sed -r -i '' "s/version_release = \'[0-9]+\.[0-9]+\.[0-9]+\'/version_release = \'$releaseversion\'/g" segment-appsflyer-ios.podspec - -sed -r -i '' "s/(.*pod \'segment-appsflyer-ios\')(.*)/\1,\'$releaseversion\'/g" examples/SwiftPodsSample/Podfile -sed -r -i '' "s/(.*pod \'segment-appsflyer-ios\')(.*)/\1,\'$releaseversion\'/g" examples/ObjcPodsSample/Podfile - sed -i '' 's/^/* /' "releasenotes.$releaseversion" NEW_VERSION_RELEASE_NOTES=$(cat "releasenotes.$releaseversion") -NEW_VERSION_SECTION="### $releaseversion\n* Updated iOS SDK to v$releaseversion\n$NEW_VERSION_RELEASE_NOTES\n\n" +NEW_VERSION_SECTION="### $releaseversion\n$NEW_VERSION_RELEASE_NOTES\n\n" echo -e "$NEW_VERSION_SECTION$(cat RELEASENOTES.md)" > RELEASENOTES.md rm -r "releasenotes.$releaseversion" \ No newline at end of file diff --git a/.github/workflows/prepare-for-release-workflow.yml b/.github/workflows/prepare-for-release-workflow.yml index 9aa1a17..6f7170a 100644 --- a/.github/workflows/prepare-for-release-workflow.yml +++ b/.github/workflows/prepare-for-release-workflow.yml @@ -1,34 +1,34 @@ -# name: Prepare plugin for production +name: Prepare plugin for production -# on: -# pull_request: -# types: -# - opened -# branches: -# # - 'master' -# - 'dev/add-release-workflow' +on: + pull_request: + types: + - opened + branches: + # - 'master' + - 'dev/add-release-workflow' -# jobs: -# Prepare-Plugin-For-Production: -# if: startsWith(github.head_ref, 'releases/') -# name: Prepare for production after testing the plugin -# runs-on: ubuntu-latest -# steps: -# - name: Checkout -# uses: actions/checkout@v3 -# - name: PR branch check -# uses: mdecoleman/pr-branch-name@1.2.0 -# id: vars -# with: -# repo-token: ${{ secrets.CI_GITHUB_TOKEN }} -# - name: Determine release tag and release branch -# run: | -# TAG=$(echo "${{ steps.vars.outputs.branch }}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') -# echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV -# - name: run script -# run: bash .github/bash_scripts/release.sh ${{env.PLUGIN_VERSION}} -# - name: Commit and Push -# run : | -# git add . -# git commit -m"Commited from github action - prepaing the repo for production." -# git push origin HEAD:${{ steps.vars.outputs.branch }} --force \ No newline at end of file +jobs: + Prepare-Plugin-For-Production: + if: startsWith(github.head_ref, 'releases/') + name: Prepare for production after testing the plugin + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: PR branch check + uses: mdecoleman/pr-branch-name@1.2.0 + id: vars + with: + repo-token: ${{ secrets.CI_GITHUB_TOKEN }} + - name: Determine release tag and release branch + run: | + TAG=$(echo "${{ steps.vars.outputs.branch }}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') + echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV + - name: run script + run: bash .github/bash_scripts/release.sh ${{env.PLUGIN_VERSION}} + - name: Commit and Push + run : | + git add . + git commit -m"Commited from github action - prepaing the repo for production." + git push origin HEAD:${{ steps.vars.outputs.branch }} --force \ No newline at end of file diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index c0c098d..a9325f2 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -11,7 +11,7 @@ on: jobs: Deploy-To-Production: if: github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/') - runs-on: macos-latest + runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v3 @@ -26,37 +26,63 @@ jobs: echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV echo "RELEASE_BRANCH_NAME=${{ steps.vars.outputs.branch }}" >> $GITHUB_ENV echo "push new release >> $TAG" - # - name: Create release and tag - # env: - # TAG: ${{env.PLUGIN_VERSION}} - # uses: "actions/github-script@v5" - # with: - # script: | - # try { - # await github.rest.repos.createRelease({ - # draft: false, - # generate_release_notes: false, - # name: process.env.TAG, - # owner: context.repo.owner, - # prerelease: false, - # repo: context.repo.repo, - # tag_name: process.env.TAG - # }); - # } catch (error) { - # core.setFailed(error.message); - # } - - name: Install Cocoapods - run: gem install cocoapods - # - name: Push to COCOAPODS - # uses: michaelhenry/deploy-to-cocoapods-github-action@1.0.10 - # env: - # COCOAPODS_TRUNK_TOKEN: ${{ secrets.CI_COCOAPODS_TOKEN }} - - name: Notify with SLack - uses: slackapi/slack-github-action@v1.23.0 + - name: Create release and tag + env: + TAG: ${{env.PLUGIN_VERSION}} + uses: "actions/github-script@v5" with: - payload: | - { - "appsflyer_version": "${{env.PLUGIN_VERSION}}" + script: | + try { + await github.rest.repos.createRelease({ + draft: false, + generate_release_notes: false, + name: process.env.TAG, + owner: context.repo.owner, + prerelease: false, + repo: context.repo.repo, + tag_name: process.env.TAG + }); + } catch (error) { + core.setFailed(error.message); } + - name: Set up Java 8 JDK + uses: actions/setup-java@v2 + with: + distribution: 'temurin' + java-version: 17 + architecture: x64 + cache: 'gradle' + check-latest: true + + - name: Decode GPG Key + run: | + mkdir -p ~/.gradle/ + echo "${{secrets.OSSRH_GPG_SECRET_KEY}}" > ~/.gradle/secring.gpg.b64 + base64 -d ~/.gradle/secring.gpg.b64 > ~/.gradle/secring.gpg + + - name: Publish package + # wraped the signing.password with single quotes as the password could contain special characters + run: ./gradlew publish -Psigning.keyId=${{secrets.OSSRH_GPG_SECRET_KEY_ID}} -Psigning.password='${{secrets.OSSRH_GPG_SECRET_KEY_PASSWORD}}' -Psigning.secretKeyRingFile=$(echo ~/.gradle/secring.gpg) --warn --stacktrace env: - SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} + OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}} + OSSRH_PASSWORD: ${{secrets.OSSRH_PASSWORD}} + + # Step 8 + # Optional step, will enable you to see what you have released as well here on GitHub + - name: Upload Artifacts + uses: actions/upload-artifact@v2 + with: + name: release-build-libs + path: build/libs + retention-days: 3 + + + # - name: Notify with SLack + # uses: slackapi/slack-github-action@v1.23.0 + # with: + # payload: | + # { + # "appsflyer_version": "${{env.PLUGIN_VERSION}}" + # } + # env: + # SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} From 01540024b0f95759e0ba27e967906bd16cdb531a Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Wed, 22 Mar 2023 16:02:29 +0200 Subject: [PATCH 07/44] yml changes --- .github/workflows/prepare-for-QA-release.yml | 7 +++++-- .github/workflows/release-QA-workflow.yml | 11 ++++++----- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index d3de42a..c8d15fe 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -9,11 +9,14 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v2 - name: Determine release tag and release branch run: | TAG=$(echo "${{github.ref_name}}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') - echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV + echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV + ls -l + cd app + ls -l - name: run script run: bash .github/bash_scripts/pre_release.sh ${{env.PLUGIN_VERSION}} - name: Commit changes diff --git a/.github/workflows/release-QA-workflow.yml b/.github/workflows/release-QA-workflow.yml index 9daf908..4d1dd97 100644 --- a/.github/workflows/release-QA-workflow.yml +++ b/.github/workflows/release-QA-workflow.yml @@ -20,12 +20,13 @@ jobs: releasenotesfile: - 'releasenotes.**' - Run-Unit-Tests: - needs: Check-If-ReleaseNotes-Pushed - if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' - uses: ./.github/workflows/unit-tests-workflow.yml + # Run-Unit-Tests: + # needs: Check-If-ReleaseNotes-Pushed + # if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' + # uses: ./.github/workflows/unit-tests-workflow.yml Deploy-Locally-To-QA: - needs: [Run-Unit-Tests,Check-If-ReleaseNotes-Pushed] + # needs: [Run-Unit-Tests,Check-If-ReleaseNotes-Pushed] + needs: Check-If-ReleaseNotes-Pushed if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' uses: ./.github/workflows/prepare-for-QA-release.yml From ca6f175d218e5db9176adc683141e9f7fa955cfd Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Wed, 22 Mar 2023 16:35:32 +0200 Subject: [PATCH 08/44] changed machine --- .github/workflows/prepare-for-QA-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index c8d15fe..b32e31c 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -6,7 +6,7 @@ on: jobs: Change-HardCoded-Version: name: Pre Release - runs-on: ubuntu-latest + runs-on: macos-latest steps: - name: Checkout uses: actions/checkout@v2 From bca087052368600a1f07e84318d83561ad1d0193 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Thu, 23 Mar 2023 13:28:14 +0200 Subject: [PATCH 09/44] self-host --- .github/workflows/prepare-for-QA-release.yml | 2 +- .github/workflows/release-QA-workflow.yml | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index b32e31c..2a93325 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -6,7 +6,7 @@ on: jobs: Change-HardCoded-Version: name: Pre Release - runs-on: macos-latest + # runs-on: macos-latest steps: - name: Checkout uses: actions/checkout@v2 diff --git a/.github/workflows/release-QA-workflow.yml b/.github/workflows/release-QA-workflow.yml index 4d1dd97..9574d9c 100644 --- a/.github/workflows/release-QA-workflow.yml +++ b/.github/workflows/release-QA-workflow.yml @@ -8,7 +8,9 @@ on: jobs: Check-If-ReleaseNotes-Pushed: - runs-on: ubuntu-latest + runs-on: + - self-hosted + - segment-android outputs: answer: ${{ steps.filter.outputs.releasenotesfile }} steps: From 942da7a9198b30d83381b677c17aeeafd86bc266 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Thu, 23 Mar 2023 13:30:04 +0200 Subject: [PATCH 10/44] runs-on added --- .github/workflows/prepare-for-QA-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index 2a93325..b32e31c 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -6,7 +6,7 @@ on: jobs: Change-HardCoded-Version: name: Pre Release - # runs-on: macos-latest + runs-on: macos-latest steps: - name: Checkout uses: actions/checkout@v2 From 909ea212f4af74f58597626d85f19cf8571547e2 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Thu, 23 Mar 2023 13:33:07 +0200 Subject: [PATCH 11/44] self-host in canonical workflows --- .github/workflows/prepare-for-QA-release.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index b32e31c..b45b80c 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -6,7 +6,10 @@ on: jobs: Change-HardCoded-Version: name: Pre Release - runs-on: macos-latest + # runs-on: macos-latest + runs-on: + - self-hosted + - segment-android steps: - name: Checkout uses: actions/checkout@v2 From a8a8ac7493b8e840e7fe224ffc01432f0874bf24 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Thu, 23 Mar 2023 13:42:56 +0200 Subject: [PATCH 12/44] self-host all the workflows --- .github/workflows/prepare-for-release-workflow.yml | 5 ++++- .github/workflows/release-production-workflow.yml | 7 +++++-- .github/workflows/unit-tests-workflow.yml | 5 ++++- 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/.github/workflows/prepare-for-release-workflow.yml b/.github/workflows/prepare-for-release-workflow.yml index 6f7170a..68f7ef7 100644 --- a/.github/workflows/prepare-for-release-workflow.yml +++ b/.github/workflows/prepare-for-release-workflow.yml @@ -12,7 +12,10 @@ jobs: Prepare-Plugin-For-Production: if: startsWith(github.head_ref, 'releases/') name: Prepare for production after testing the plugin - runs-on: ubuntu-latest + # runs-on: ubuntu-latest + runs-on: + - self-hosted + - segment-android steps: - name: Checkout uses: actions/checkout@v3 diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index a9325f2..db2e38b 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -11,7 +11,10 @@ on: jobs: Deploy-To-Production: if: github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/') - runs-on: ubuntu-latest + # runs-on: ubuntu-latest + runs-on: + - self-hosted + - segment-android steps: - name: Checkout uses: actions/checkout@v3 @@ -53,7 +56,7 @@ jobs: architecture: x64 cache: 'gradle' check-latest: true - + - name: Decode GPG Key run: | mkdir -p ~/.gradle/ diff --git a/.github/workflows/unit-tests-workflow.yml b/.github/workflows/unit-tests-workflow.yml index 45e6d92..4203e1b 100644 --- a/.github/workflows/unit-tests-workflow.yml +++ b/.github/workflows/unit-tests-workflow.yml @@ -8,7 +8,10 @@ on: workflow_call: jobs: Tests: - runs-on: ubuntu-latest + # runs-on: ubuntu-latest + runs-on: + - self-hosted + - segment-android steps: - uses: actions/checkout@v2 - name: Set up JDK From 5bbb491938c9beee12c911c9005343dcc8f656a3 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Thu, 23 Mar 2023 14:18:52 +0200 Subject: [PATCH 13/44] uses local .gnupg/secring.gpg file on self-host --- .github/workflows/release-production-workflow.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index db2e38b..15b740c 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -57,15 +57,15 @@ jobs: cache: 'gradle' check-latest: true - - name: Decode GPG Key - run: | - mkdir -p ~/.gradle/ - echo "${{secrets.OSSRH_GPG_SECRET_KEY}}" > ~/.gradle/secring.gpg.b64 - base64 -d ~/.gradle/secring.gpg.b64 > ~/.gradle/secring.gpg + # - name: Decode GPG Key + # run: | + # mkdir -p ~/.gradle/ + # echo "${{secrets.OSSRH_GPG_SECRET_KEY}}" > ~/.gradle/secring.gpg.b64 + # base64 -d ~/.gradle/secring.gpg.b64 > ~/.gradle/secring.gpg - name: Publish package # wraped the signing.password with single quotes as the password could contain special characters - run: ./gradlew publish -Psigning.keyId=${{secrets.OSSRH_GPG_SECRET_KEY_ID}} -Psigning.password='${{secrets.OSSRH_GPG_SECRET_KEY_PASSWORD}}' -Psigning.secretKeyRingFile=$(echo ~/.gradle/secring.gpg) --warn --stacktrace + run: ./gradlew publish -Psigning.keyId=${{secrets.OSSRH_GPG_SECRET_KEY_ID}} -Psigning.password='${{secrets.OSSRH_GPG_SECRET_KEY_PASSWORD}}' -Psigning.secretKeyRingFile=$(echo ~/.gnupg/secring.gpg) --warn --stacktrace env: OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}} OSSRH_PASSWORD: ${{secrets.OSSRH_PASSWORD}} From e776feb0a2db4e17230ba905f9cb9e27a2297813 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Thu, 23 Mar 2023 15:10:33 +0200 Subject: [PATCH 14/44] gradle publish from local repo. --- .github/workflows/release-production-workflow.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index 15b740c..273527f 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -65,7 +65,7 @@ jobs: - name: Publish package # wraped the signing.password with single quotes as the password could contain special characters - run: ./gradlew publish -Psigning.keyId=${{secrets.OSSRH_GPG_SECRET_KEY_ID}} -Psigning.password='${{secrets.OSSRH_GPG_SECRET_KEY_PASSWORD}}' -Psigning.secretKeyRingFile=$(echo ~/.gnupg/secring.gpg) --warn --stacktrace + run: ~/Desktop/AppsFlyer/Segment/appsflyer-segment-android-plugin/gradlew publish env: OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}} OSSRH_PASSWORD: ${{secrets.OSSRH_PASSWORD}} From 2f3916a873026137bd55a6232077c01920787428 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 26 Mar 2023 10:52:47 +0300 Subject: [PATCH 15/44] deploy process + in-memory-signing --- .../workflows/release-production-workflow.yml | 68 +++++++++++-------- app/publish.gradle | 10 ++- 2 files changed, 50 insertions(+), 28 deletions(-) diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index 273527f..eeb01b4 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -29,25 +29,25 @@ jobs: echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV echo "RELEASE_BRANCH_NAME=${{ steps.vars.outputs.branch }}" >> $GITHUB_ENV echo "push new release >> $TAG" - - name: Create release and tag - env: - TAG: ${{env.PLUGIN_VERSION}} - uses: "actions/github-script@v5" - with: - script: | - try { - await github.rest.repos.createRelease({ - draft: false, - generate_release_notes: false, - name: process.env.TAG, - owner: context.repo.owner, - prerelease: false, - repo: context.repo.repo, - tag_name: process.env.TAG - }); - } catch (error) { - core.setFailed(error.message); - } + # - name: Create release and tag + # env: + # TAG: ${{env.PLUGIN_VERSION}} + # uses: "actions/github-script@v5" + # with: + # script: | + # try { + # await github.rest.repos.createRelease({ + # draft: false, + # generate_release_notes: false, + # name: process.env.TAG, + # owner: context.repo.owner, + # prerelease: false, + # repo: context.repo.repo, + # tag_name: process.env.TAG + # }); + # } catch (error) { + # core.setFailed(error.message); + # } - name: Set up Java 8 JDK uses: actions/setup-java@v2 with: @@ -65,19 +65,33 @@ jobs: - name: Publish package # wraped the signing.password with single quotes as the password could contain special characters - run: ~/Desktop/AppsFlyer/Segment/appsflyer-segment-android-plugin/gradlew publish + # run: ~/Desktop/AppsFlyer/Segment/appsflyer-segment-android-plugin/gradlew publish env: OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}} OSSRH_PASSWORD: ${{secrets.OSSRH_PASSWORD}} + OSSRH_GPG_SECRET_KEY_ID: ${{secrets.OSSRH_GPG_SECRET_KEY_ID}} + OSSRH_GPG_SECRET_KEY_PASSWORD: ${{secrets.OSSRH_GPG_SECRET_KEY_PASSWORD}} + OSSRH_GPG_SECRET_KEY: ${{secrets.OSSRH_GPG_SECRET_KEY}} + run: | + mkdir -p "~/.gradle" + echo $OSSRH_GPG_SECRET_KEY_ID >> ~/.gradle/gradle.properties + echo $OSSRH_GPG_SECRET_KEY_PASSWORD >> ~/.gradle/gradle.properties + echo $OSSRH_PASSWORD >> ~/.gradle/gradle.properties + echo $OSSRH_USER_NAME >> ~/.gradle/gradle.properties + echo $ORG_GRADLE_PROJECT_sonatypePassword >> ~/.gradle/gradle.properties + echo $ORG_GRADLE_PROJECT_sonatypeUsername >> ~/.gradle/gradle.properties + # need to add the below secret. - > how? + cat $OSSRH_GPG_SECRET_KEY | awk 'NR == 1 { print "ORG_GRADLE_PROJECT_signingKey=" } 1' ORS='\\n' >> ~/.gradle/gradle.properties + ./gradlew clean run publishToSonaType closeSonatypeStagingRepository # Step 8 # Optional step, will enable you to see what you have released as well here on GitHub - - name: Upload Artifacts - uses: actions/upload-artifact@v2 - with: - name: release-build-libs - path: build/libs - retention-days: 3 + # - name: Upload Artifacts + # uses: actions/upload-artifact@v2 + # with: + # name: release-build-libs + # path: build/libs + # retention-days: 3 # - name: Notify with SLack @@ -88,4 +102,4 @@ jobs: # "appsflyer_version": "${{env.PLUGIN_VERSION}}" # } # env: - # SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} + # SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} \ No newline at end of file diff --git a/app/publish.gradle b/app/publish.gradle index 961640c..a7445f2 100644 --- a/app/publish.gradle +++ b/app/publish.gradle @@ -119,11 +119,19 @@ afterEvaluate { } } +// signing { +// logger("signing") +// sign publishing.publications +// } signing { - logger("signing") + def signingKeyId = findProperty("ORG_GRADLE_PROJECT_signingKeyId") + def signingKey = findProperty("ORG_GRADLE_PROJECT_signingKey") + def signingPassword = findProperty("ORG_GRADLE_PROJECT_signingPassword") + useInMemoryPgpKeys(signingKeyId, signingKey, signingPassword) sign publishing.publications } + publish.dependsOn build publishToMavenLocal.dependsOn build \ No newline at end of file From 2b3ca2b118c9e682f98db56a87c0d6bf1b59d7a7 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 26 Mar 2023 11:05:43 +0300 Subject: [PATCH 16/44] jdk update --- .github/workflows/release-production-workflow.yml | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index eeb01b4..6643f21 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -48,14 +48,10 @@ jobs: # } catch (error) { # core.setFailed(error.message); # } - - name: Set up Java 8 JDK - uses: actions/setup-java@v2 + - name: set up JDK 1.11 + uses: actions/setup-java@v1 with: - distribution: 'temurin' - java-version: 17 - architecture: x64 - cache: 'gradle' - check-latest: true + java-version: 1.11 # - name: Decode GPG Key # run: | @@ -82,7 +78,7 @@ jobs: echo $ORG_GRADLE_PROJECT_sonatypeUsername >> ~/.gradle/gradle.properties # need to add the below secret. - > how? cat $OSSRH_GPG_SECRET_KEY | awk 'NR == 1 { print "ORG_GRADLE_PROJECT_signingKey=" } 1' ORS='\\n' >> ~/.gradle/gradle.properties - ./gradlew clean run publishToSonaType closeSonatypeStagingRepository + ./gradlew clean run publishToSonaType closeSonatypeStagingRepository --warning-mode all # Step 8 # Optional step, will enable you to see what you have released as well here on GitHub From ed09782ca73c3e7833026c08b873996d382bcc33 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 26 Mar 2023 11:07:57 +0300 Subject: [PATCH 17/44] grant permissions to gradlew --- .github/workflows/release-production-workflow.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index 6643f21..f4d1fd3 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -59,6 +59,9 @@ jobs: # echo "${{secrets.OSSRH_GPG_SECRET_KEY}}" > ~/.gradle/secring.gpg.b64 # base64 -d ~/.gradle/secring.gpg.b64 > ~/.gradle/secring.gpg + - name: Grant execute permission for gradlew + run: chmod +x ./gradlew + - name: Publish package # wraped the signing.password with single quotes as the password could contain special characters # run: ~/Desktop/AppsFlyer/Segment/appsflyer-segment-android-plugin/gradlew publish From 329c70a8d98d7bba97fd2db6f44b57f9c0a2d763 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 26 Mar 2023 16:30:02 +0300 Subject: [PATCH 18/44] using local props --- .../workflows/release-production-workflow.yml | 35 ++++++++++--------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index f4d1fd3..5a25f32 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -60,28 +60,29 @@ jobs: # base64 -d ~/.gradle/secring.gpg.b64 > ~/.gradle/secring.gpg - name: Grant execute permission for gradlew - run: chmod +x ./gradlew + run: | + chmod +x ./gradlew - name: Publish package # wraped the signing.password with single quotes as the password could contain special characters # run: ~/Desktop/AppsFlyer/Segment/appsflyer-segment-android-plugin/gradlew publish - env: - OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}} - OSSRH_PASSWORD: ${{secrets.OSSRH_PASSWORD}} - OSSRH_GPG_SECRET_KEY_ID: ${{secrets.OSSRH_GPG_SECRET_KEY_ID}} - OSSRH_GPG_SECRET_KEY_PASSWORD: ${{secrets.OSSRH_GPG_SECRET_KEY_PASSWORD}} - OSSRH_GPG_SECRET_KEY: ${{secrets.OSSRH_GPG_SECRET_KEY}} + # env: + # OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}} + # OSSRH_PASSWORD: ${{secrets.OSSRH_PASSWORD}} + # OSSRH_GPG_SECRET_KEY_ID: ${{secrets.OSSRH_GPG_SECRET_KEY_ID}} + # OSSRH_GPG_SECRET_KEY_PASSWORD: ${{secrets.OSSRH_GPG_SECRET_KEY_PASSWORD}} + # OSSRH_GPG_SECRET_KEY: ${{secrets.OSSRH_GPG_SECRET_KEY}} + # run: | + # mkdir -p "~/.gradle" + # rm ~/.gradle/gradle.properties + # echo $OSSRH_GPG_SECRET_KEY_ID >> ~/.gradle/gradle.properties + # echo $OSSRH_GPG_SECRET_KEY_PASSWORD >> ~/.gradle/gradle.properties + # echo $OSSRH_PASSWORD >> ~/.gradle/gradle.properties + # echo $OSSRH_USER_NAME >> ~/.gradle/gradle.properties + # echo "$OSSRH_GPG_SECRET_KEY" | awk 'NR == 1 { print "ORG_GRADLE_PROJECT_signingKey=" } 1' ORS='\\n' >> ~/.gradle/gradle.properties + # ./gradlew clean run publishToSonaType closeSonatypeStagingRepository run: | - mkdir -p "~/.gradle" - echo $OSSRH_GPG_SECRET_KEY_ID >> ~/.gradle/gradle.properties - echo $OSSRH_GPG_SECRET_KEY_PASSWORD >> ~/.gradle/gradle.properties - echo $OSSRH_PASSWORD >> ~/.gradle/gradle.properties - echo $OSSRH_USER_NAME >> ~/.gradle/gradle.properties - echo $ORG_GRADLE_PROJECT_sonatypePassword >> ~/.gradle/gradle.properties - echo $ORG_GRADLE_PROJECT_sonatypeUsername >> ~/.gradle/gradle.properties - # need to add the below secret. - > how? - cat $OSSRH_GPG_SECRET_KEY | awk 'NR == 1 { print "ORG_GRADLE_PROJECT_signingKey=" } 1' ORS='\\n' >> ~/.gradle/gradle.properties - ./gradlew clean run publishToSonaType closeSonatypeStagingRepository --warning-mode all + ./gradlew publish # Step 8 # Optional step, will enable you to see what you have released as well here on GitHub From 97bcca3c00fe8e86fdf811e6f68a307d4afda1a6 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 12:33:18 +0300 Subject: [PATCH 19/44] config changes --- .../workflows/release-production-workflow.yml | 4 ++-- app/publish.gradle | 22 +++++++++---------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index 5a25f32..e9bd88b 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -48,10 +48,10 @@ jobs: # } catch (error) { # core.setFailed(error.message); # } - - name: set up JDK 1.11 + - name: Set up JDK uses: actions/setup-java@v1 with: - java-version: 1.11 + java-version: '11' # - name: Decode GPG Key # run: | diff --git a/app/publish.gradle b/app/publish.gradle index a7445f2..e8a070e 100644 --- a/app/publish.gradle +++ b/app/publish.gradle @@ -119,17 +119,17 @@ afterEvaluate { } } -// signing { -// logger("signing") -// sign publishing.publications -// } -signing { - def signingKeyId = findProperty("ORG_GRADLE_PROJECT_signingKeyId") - def signingKey = findProperty("ORG_GRADLE_PROJECT_signingKey") - def signingPassword = findProperty("ORG_GRADLE_PROJECT_signingPassword") - useInMemoryPgpKeys(signingKeyId, signingKey, signingPassword) - sign publishing.publications -} + signing { + logger("signing") + sign publishing.publications + } +//signing { +// def signingKeyId = findProperty("ORG_GRADLE_PROJECT_signingKeyId") +// def signingKey = findProperty("ORG_GRADLE_PROJECT_signingKey") +// def signingPassword = findProperty("ORG_GRADLE_PROJECT_signingPassword") +// useInMemoryPgpKeys(signingKeyId, signingKey, signingPassword) +// sign publishing.publications +//} From fe897346a8bef2b0c72e5137ee5dd1248fc8cf1b Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 12:41:39 +0300 Subject: [PATCH 20/44] testing staging --- .../workflows/release-production-workflow.yml | 64 +++++++++---------- 1 file changed, 29 insertions(+), 35 deletions(-) diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index e9bd88b..7e86586 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -29,35 +29,29 @@ jobs: echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV echo "RELEASE_BRANCH_NAME=${{ steps.vars.outputs.branch }}" >> $GITHUB_ENV echo "push new release >> $TAG" - # - name: Create release and tag - # env: - # TAG: ${{env.PLUGIN_VERSION}} - # uses: "actions/github-script@v5" - # with: - # script: | - # try { - # await github.rest.repos.createRelease({ - # draft: false, - # generate_release_notes: false, - # name: process.env.TAG, - # owner: context.repo.owner, - # prerelease: false, - # repo: context.repo.repo, - # tag_name: process.env.TAG - # }); - # } catch (error) { - # core.setFailed(error.message); - # } + - name: Create release and tag + env: + TAG: ${{env.PLUGIN_VERSION}} + uses: "actions/github-script@v5" + with: + script: | + try { + await github.rest.repos.createRelease({ + draft: false, + generate_release_notes: false, + name: process.env.TAG, + owner: context.repo.owner, + prerelease: false, + repo: context.repo.repo, + tag_name: process.env.TAG + }); + } catch (error) { + core.setFailed(error.message); + } - name: Set up JDK uses: actions/setup-java@v1 with: - java-version: '11' - - # - name: Decode GPG Key - # run: | - # mkdir -p ~/.gradle/ - # echo "${{secrets.OSSRH_GPG_SECRET_KEY}}" > ~/.gradle/secring.gpg.b64 - # base64 -d ~/.gradle/secring.gpg.b64 > ~/.gradle/secring.gpg + java-version: '11' - name: Grant execute permission for gradlew run: | @@ -94,12 +88,12 @@ jobs: # retention-days: 3 - # - name: Notify with SLack - # uses: slackapi/slack-github-action@v1.23.0 - # with: - # payload: | - # { - # "appsflyer_version": "${{env.PLUGIN_VERSION}}" - # } - # env: - # SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} \ No newline at end of file + - name: Notify with SLack + uses: slackapi/slack-github-action@v1.23.0 + with: + payload: | + { + "appsflyer_version": "${{env.PLUGIN_VERSION}}" + } + env: + SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} \ No newline at end of file From 87a8271d65907fd6a34826655ccc5b8bc950593a Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 14:45:44 +0300 Subject: [PATCH 21/44] name changing --- .github/workflows/release-production-workflow.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index 7e86586..e7cc434 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -88,7 +88,7 @@ jobs: # retention-days: 3 - - name: Notify with SLack + - name: Notify with Slack uses: slackapi/slack-github-action@v1.23.0 with: payload: | From 3b1befa13d7b6dea7dc2e454456c4c95a059e8f5 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 14:47:52 +0300 Subject: [PATCH 22/44] change runs-on --- .github/workflows/prepare-for-QA-release.yml | 1 - .github/workflows/prepare-for-release-workflow.yml | 1 - .github/workflows/release-QA-workflow.yml | 1 - .github/workflows/release-production-workflow.yml | 1 - .github/workflows/unit-tests-workflow.yml | 1 - 5 files changed, 5 deletions(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index b45b80c..a5b17a7 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -9,7 +9,6 @@ jobs: # runs-on: macos-latest runs-on: - self-hosted - - segment-android steps: - name: Checkout uses: actions/checkout@v2 diff --git a/.github/workflows/prepare-for-release-workflow.yml b/.github/workflows/prepare-for-release-workflow.yml index 68f7ef7..b30c958 100644 --- a/.github/workflows/prepare-for-release-workflow.yml +++ b/.github/workflows/prepare-for-release-workflow.yml @@ -15,7 +15,6 @@ jobs: # runs-on: ubuntu-latest runs-on: - self-hosted - - segment-android steps: - name: Checkout uses: actions/checkout@v3 diff --git a/.github/workflows/release-QA-workflow.yml b/.github/workflows/release-QA-workflow.yml index 9574d9c..d004383 100644 --- a/.github/workflows/release-QA-workflow.yml +++ b/.github/workflows/release-QA-workflow.yml @@ -10,7 +10,6 @@ jobs: Check-If-ReleaseNotes-Pushed: runs-on: - self-hosted - - segment-android outputs: answer: ${{ steps.filter.outputs.releasenotesfile }} steps: diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index e7cc434..336c8ef 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -14,7 +14,6 @@ jobs: # runs-on: ubuntu-latest runs-on: - self-hosted - - segment-android steps: - name: Checkout uses: actions/checkout@v3 diff --git a/.github/workflows/unit-tests-workflow.yml b/.github/workflows/unit-tests-workflow.yml index 4203e1b..335d262 100644 --- a/.github/workflows/unit-tests-workflow.yml +++ b/.github/workflows/unit-tests-workflow.yml @@ -11,7 +11,6 @@ jobs: # runs-on: ubuntu-latest runs-on: - self-hosted - - segment-android steps: - uses: actions/checkout@v2 - name: Set up JDK From 0e4050cc6a18874890525501a71fdb82ff9a5f5e Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 15:05:48 +0300 Subject: [PATCH 23/44] getting ready for last testing on mini mac --- .github/workflows/prepare-for-QA-release.yml | 3 +- .../prepare-for-release-workflow.yml | 2 +- .github/workflows/release-QA-workflow.yml | 12 +++---- .../workflows/release-production-workflow.yml | 34 ++----------------- .github/workflows/unit-tests-workflow.yml | 2 +- 5 files changed, 12 insertions(+), 41 deletions(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index a5b17a7..cf785c0 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -6,9 +6,10 @@ on: jobs: Change-HardCoded-Version: name: Pre Release - # runs-on: macos-latest runs-on: - self-hosted + - segment-android-mini-mac-runner + steps: - name: Checkout uses: actions/checkout@v2 diff --git a/.github/workflows/prepare-for-release-workflow.yml b/.github/workflows/prepare-for-release-workflow.yml index b30c958..34108fd 100644 --- a/.github/workflows/prepare-for-release-workflow.yml +++ b/.github/workflows/prepare-for-release-workflow.yml @@ -12,9 +12,9 @@ jobs: Prepare-Plugin-For-Production: if: startsWith(github.head_ref, 'releases/') name: Prepare for production after testing the plugin - # runs-on: ubuntu-latest runs-on: - self-hosted + - segment-android-mini-mac-runner steps: - name: Checkout uses: actions/checkout@v3 diff --git a/.github/workflows/release-QA-workflow.yml b/.github/workflows/release-QA-workflow.yml index d004383..c25a5de 100644 --- a/.github/workflows/release-QA-workflow.yml +++ b/.github/workflows/release-QA-workflow.yml @@ -10,6 +10,7 @@ jobs: Check-If-ReleaseNotes-Pushed: runs-on: - self-hosted + - segment-android-mini-mac-runner outputs: answer: ${{ steps.filter.outputs.releasenotesfile }} steps: @@ -21,13 +22,12 @@ jobs: releasenotesfile: - 'releasenotes.**' - # Run-Unit-Tests: - # needs: Check-If-ReleaseNotes-Pushed - # if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' - # uses: ./.github/workflows/unit-tests-workflow.yml + Run-Unit-Tests: + needs: Check-If-ReleaseNotes-Pushed + if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' + uses: ./.github/workflows/unit-tests-workflow.yml Deploy-Locally-To-QA: - # needs: [Run-Unit-Tests,Check-If-ReleaseNotes-Pushed] - needs: Check-If-ReleaseNotes-Pushed + needs: [Run-Unit-Tests,Check-If-ReleaseNotes-Pushed] if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' uses: ./.github/workflows/prepare-for-QA-release.yml diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index 336c8ef..ebb7e7e 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -11,9 +11,9 @@ on: jobs: Deploy-To-Production: if: github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/') - # runs-on: ubuntu-latest runs-on: - self-hosted + - segment-android-mini-mac-runner steps: - name: Checkout uses: actions/checkout@v3 @@ -21,7 +21,7 @@ jobs: uses: mdecoleman/pr-branch-name@1.2.0 id: vars with: - repo-token: ${{ secrets.CI_GITHUB_TOKEN }} + repo-token: ${{ secrets.CI_GITHUB_TOKEN }} - name: Determine release tag and release branch run: | TAG=$(echo "${{ steps.vars.outputs.branch }}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') @@ -51,42 +51,12 @@ jobs: uses: actions/setup-java@v1 with: java-version: '11' - - name: Grant execute permission for gradlew run: | chmod +x ./gradlew - - name: Publish package - # wraped the signing.password with single quotes as the password could contain special characters - # run: ~/Desktop/AppsFlyer/Segment/appsflyer-segment-android-plugin/gradlew publish - # env: - # OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}} - # OSSRH_PASSWORD: ${{secrets.OSSRH_PASSWORD}} - # OSSRH_GPG_SECRET_KEY_ID: ${{secrets.OSSRH_GPG_SECRET_KEY_ID}} - # OSSRH_GPG_SECRET_KEY_PASSWORD: ${{secrets.OSSRH_GPG_SECRET_KEY_PASSWORD}} - # OSSRH_GPG_SECRET_KEY: ${{secrets.OSSRH_GPG_SECRET_KEY}} - # run: | - # mkdir -p "~/.gradle" - # rm ~/.gradle/gradle.properties - # echo $OSSRH_GPG_SECRET_KEY_ID >> ~/.gradle/gradle.properties - # echo $OSSRH_GPG_SECRET_KEY_PASSWORD >> ~/.gradle/gradle.properties - # echo $OSSRH_PASSWORD >> ~/.gradle/gradle.properties - # echo $OSSRH_USER_NAME >> ~/.gradle/gradle.properties - # echo "$OSSRH_GPG_SECRET_KEY" | awk 'NR == 1 { print "ORG_GRADLE_PROJECT_signingKey=" } 1' ORS='\\n' >> ~/.gradle/gradle.properties - # ./gradlew clean run publishToSonaType closeSonatypeStagingRepository run: | ./gradlew publish - - # Step 8 - # Optional step, will enable you to see what you have released as well here on GitHub - # - name: Upload Artifacts - # uses: actions/upload-artifact@v2 - # with: - # name: release-build-libs - # path: build/libs - # retention-days: 3 - - - name: Notify with Slack uses: slackapi/slack-github-action@v1.23.0 with: diff --git a/.github/workflows/unit-tests-workflow.yml b/.github/workflows/unit-tests-workflow.yml index 335d262..f88f4e8 100644 --- a/.github/workflows/unit-tests-workflow.yml +++ b/.github/workflows/unit-tests-workflow.yml @@ -8,9 +8,9 @@ on: workflow_call: jobs: Tests: - # runs-on: ubuntu-latest runs-on: - self-hosted + - segment-android-mini-mac-runner steps: - uses: actions/checkout@v2 - name: Set up JDK From ecf2576d1f521791b1e43fce54908cc4b07936f3 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 15:08:14 +0300 Subject: [PATCH 24/44] Commited from github action - prepaing the repo for QA locally. --- releasenotes.6.10.2 | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 releasenotes.6.10.2 diff --git a/releasenotes.6.10.2 b/releasenotes.6.10.2 new file mode 100644 index 0000000..e69de29 From 6c39c79f26a8de5ad84ebb867b9d92a92031be4c Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 15:09:25 +0300 Subject: [PATCH 25/44] notes added --- releasenotes.6.10.2 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/releasenotes.6.10.2 b/releasenotes.6.10.2 index e69de29..eddfeaf 100644 --- a/releasenotes.6.10.2 +++ b/releasenotes.6.10.2 @@ -0,0 +1,3 @@ +Update Android SDK to v6.10.2 +Moris +Testing notes \ No newline at end of file From 405e6620c7af3137731a6760f8b65b498980ed44 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 15:11:18 +0300 Subject: [PATCH 26/44] Commited from github action - prepaing the repo for production. --- RELEASENOTES.md | 5 +++++ releasenotes.6.10.2 | 3 --- 2 files changed, 5 insertions(+), 3 deletions(-) delete mode 100644 releasenotes.6.10.2 diff --git a/RELEASENOTES.md b/RELEASENOTES.md index dcb8e74..b1d0ce5 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -1,3 +1,8 @@ +### 6.10.2 +* Update Android SDK to v6.10.2 +* Moris +* Testing notes + ### 6.10.1 * Update Android SDK to v6.10.1 * Added unit tests. diff --git a/releasenotes.6.10.2 b/releasenotes.6.10.2 deleted file mode 100644 index eddfeaf..0000000 --- a/releasenotes.6.10.2 +++ /dev/null @@ -1,3 +0,0 @@ -Update Android SDK to v6.10.2 -Moris -Testing notes \ No newline at end of file From 3f9562f7161df96af3a86b79be28d92bea401aa7 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 15:27:29 +0300 Subject: [PATCH 27/44] chnaging releasenotes --- RELEASENOTES.md | 5 ----- 1 file changed, 5 deletions(-) diff --git a/RELEASENOTES.md b/RELEASENOTES.md index b1d0ce5..dcb8e74 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -1,8 +1,3 @@ -### 6.10.2 -* Update Android SDK to v6.10.2 -* Moris -* Testing notes - ### 6.10.1 * Update Android SDK to v6.10.1 * Added unit tests. From 323f1fad760783291925e1eae8c4e1332a2a01e6 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 16:26:27 +0300 Subject: [PATCH 28/44] changes sed flag to work on mini mac --- .github/bash_scripts/pre_release.sh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/bash_scripts/pre_release.sh b/.github/bash_scripts/pre_release.sh index 0c1ea46..28c0993 100644 --- a/.github/bash_scripts/pre_release.sh +++ b/.github/bash_scripts/pre_release.sh @@ -2,18 +2,18 @@ appsflyerversion=$1 -sed -r -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$appsflyerversion\'/g" app/build.gradle +sed -E -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$appsflyerversion\'/g" app/build.gradle -sed -r -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$appsflyerversion\'/g" segmenttestapp/build.gradle +sed -E -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$appsflyerversion\'/g" segmenttestapp/build.gradle version_code=$(grep -E 'VERSION_CODE=([0-9]+)' gradle.properties | grep -o '[0-9]\+') version_code=$((version_code+1)) -sed -r -i '' "s/VERSION_CODE=([0-9]+)/VERSION_CODE=$version_code/g" gradle.properties +sed -E -i '' "s/VERSION_CODE=([0-9]+)/VERSION_CODE=$version_code/g" gradle.properties -sed -r -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+)/VERSION_NAME=$appsflyerversion/g" gradle.properties +sed -E -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+)/VERSION_NAME=$appsflyerversion/g" gradle.properties -sed -r -i '' "s/(Built with AppsFlyer Android SDK.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md -sed -r -i '' "s/(.*appsflyer:segment-android-integration:)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md -sed -r -i '' "s/(.*Maven Central.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3$appsflyerversion\5/g" Readme.md +sed -E -i '' "s/(Built with AppsFlyer Android SDK.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md +sed -E -i '' "s/(.*appsflyer:segment-android-integration:)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md +sed -E -i '' "s/(.*Maven Central.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3$appsflyerversion\5/g" Readme.md touch "releasenotes.$appsflyerversion" From 9a161f7ac1e9111a154f4bed5b82c98592ffd674 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 16:51:25 +0300 Subject: [PATCH 29/44] run change in a step --- .github/workflows/prepare-for-QA-release.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index cf785c0..c1ac96a 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -17,9 +17,6 @@ jobs: run: | TAG=$(echo "${{github.ref_name}}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV - ls -l - cd app - ls -l - name: run script run: bash .github/bash_scripts/pre_release.sh ${{env.PLUGIN_VERSION}} - name: Commit changes From fabd79379339f34d7256f7ea901d7e1eaa40c962 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 16:53:55 +0300 Subject: [PATCH 30/44] removing redundant branch_ignore --- .github/workflows/unit-tests-workflow.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/unit-tests-workflow.yml b/.github/workflows/unit-tests-workflow.yml index f88f4e8..e9cf866 100644 --- a/.github/workflows/unit-tests-workflow.yml +++ b/.github/workflows/unit-tests-workflow.yml @@ -2,7 +2,6 @@ name: CI - Tests on: push: branches-ignore: - - 'main' - 'master' - 'releases/**' workflow_call: From 7253233dced20ee76cabff15ebb7af7dd59524ff Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 27 Mar 2023 16:55:00 +0300 Subject: [PATCH 31/44] removed comment --- app/publish.gradle | 9 --------- 1 file changed, 9 deletions(-) diff --git a/app/publish.gradle b/app/publish.gradle index e8a070e..fce6aff 100644 --- a/app/publish.gradle +++ b/app/publish.gradle @@ -123,15 +123,6 @@ afterEvaluate { logger("signing") sign publishing.publications } -//signing { -// def signingKeyId = findProperty("ORG_GRADLE_PROJECT_signingKeyId") -// def signingKey = findProperty("ORG_GRADLE_PROJECT_signingKey") -// def signingPassword = findProperty("ORG_GRADLE_PROJECT_signingPassword") -// useInMemoryPgpKeys(signingKeyId, signingKey, signingPassword) -// sign publishing.publications -//} - - publish.dependsOn build publishToMavenLocal.dependsOn build \ No newline at end of file From d46ba13b8454c8f2e35df6546606e3a34b7ad35c Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 2 Apr 2023 19:24:55 +0000 Subject: [PATCH 32/44] commented the badge in script --- .github/bash_scripts/pre_release.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/bash_scripts/pre_release.sh b/.github/bash_scripts/pre_release.sh index 28c0993..829e038 100644 --- a/.github/bash_scripts/pre_release.sh +++ b/.github/bash_scripts/pre_release.sh @@ -14,6 +14,6 @@ sed -E -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+)/VERSION_NAME=$appsflyerver sed -E -i '' "s/(Built with AppsFlyer Android SDK.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md sed -E -i '' "s/(.*appsflyer:segment-android-integration:)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md -sed -E -i '' "s/(.*Maven Central.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3$appsflyerversion\5/g" Readme.md +# sed -E -i '' "s/(.*Maven Central.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3$appsflyerversion\5/g" Readme.md touch "releasenotes.$appsflyerversion" From ff05cb2ca232b056290043892121ea69536bd260 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Thu, 13 Apr 2023 15:36:23 +0300 Subject: [PATCH 33/44] added the config to setPluginInfo param --- .github/bash_scripts/pre_release.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/bash_scripts/pre_release.sh b/.github/bash_scripts/pre_release.sh index 829e038..0d8348d 100644 --- a/.github/bash_scripts/pre_release.sh +++ b/.github/bash_scripts/pre_release.sh @@ -14,6 +14,7 @@ sed -E -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+)/VERSION_NAME=$appsflyerver sed -E -i '' "s/(Built with AppsFlyer Android SDK.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md sed -E -i '' "s/(.*appsflyer:segment-android-integration:)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md -# sed -E -i '' "s/(.*Maven Central.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3$appsflyerversion\5/g" Readme.md + +sed -E -i '' "s/(.*setPluginInfo.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" app/src/main/java/com/segment/analytics/android/integrations/appsflyer/AppsflyerIntegration.java touch "releasenotes.$appsflyerversion" From 96c9dcaa6616afd6a6d3abe4a8cde557acb352ef Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 30 Apr 2023 15:24:47 +0300 Subject: [PATCH 34/44] releaseing to maven QA --- .github/bash_scripts/pre_release.sh | 5 +++- .github/workflows/prepare-for-QA-release.yml | 28 +++++++++++++++++--- 2 files changed, 29 insertions(+), 4 deletions(-) diff --git a/.github/bash_scripts/pre_release.sh b/.github/bash_scripts/pre_release.sh index 0d8348d..fdd9df6 100644 --- a/.github/bash_scripts/pre_release.sh +++ b/.github/bash_scripts/pre_release.sh @@ -1,6 +1,7 @@ #!/bin/bash appsflyerversion=$1 +rc=$2 sed -E -i '' "s/(.*af-android-sdk:)([0-9]+\.[0-9]+\.[0-9]+)'/\1$appsflyerversion\'/g" app/build.gradle @@ -10,7 +11,9 @@ version_code=$(grep -E 'VERSION_CODE=([0-9]+)' gradle.properties | grep -o '[0-9 version_code=$((version_code+1)) sed -E -i '' "s/VERSION_CODE=([0-9]+)/VERSION_CODE=$version_code/g" gradle.properties -sed -E -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+)/VERSION_NAME=$appsflyerversion/g" gradle.properties +sed -E -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+)/VERSION_NAME=$appsflyerversion-rc$rc/g" gradle.properties + +sed -E -i '' "s/(POM_ARTIFACT_ID=.*)/\1-beta/g" gradle.properties sed -E -i '' "s/(Built with AppsFlyer Android SDK.*)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md sed -E -i '' "s/(.*appsflyer:segment-android-integration:)([0-9]+\.[0-9]+\.[0-9]+)(.*)/\1$appsflyerversion\3/g" Readme.md diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index c1ac96a..e60cce0 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -16,14 +16,36 @@ jobs: - name: Determine release tag and release branch run: | TAG=$(echo "${{github.ref_name}}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') - echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV + RC=$(echo "${{github.ref_name}}" | grep -Eo '[0-9]+$') + echo "PLUGIN_VERSION=$TAG" >> $GITHUB_ENV + echo "RC_NUMBER=$RC" >> $GITHUB_ENV - name: run script - run: bash .github/bash_scripts/pre_release.sh ${{env.PLUGIN_VERSION}} + run: bash .github/bash_scripts/pre_release.sh ${{env.PLUGIN_VERSION}} ${{env.RC_NUMBER}} - name: Commit changes uses: EndBug/add-and-commit@v9 with: author_name: Moris Gateno author_email: moris.gateno@appsflyer.com message: 'Commited from github action - prepaing the repo for QA locally.' - add: '.' + add: '.' + - name: Set up JDK + uses: actions/setup-java@v1 + with: + java-version: '11' + - name: Grant execute permission for gradlew + run: | + chmod +x ./gradlew + - name: Publish package to QA (-Beta) + run: | + ./gradlew publish + - name: Notify with Slack + uses: slackapi/slack-github-action@v1.23.0 + with: + payload: | + { + "appsflyer_version": "${{env.PLUGIN_VERSION}}" + } + env: + SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} + From 4c273f31847e3e49638ff8113389808718f13056 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 30 Apr 2023 17:19:37 +0300 Subject: [PATCH 35/44] removed label --- .github/workflows/release-QA-workflow.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release-QA-workflow.yml b/.github/workflows/release-QA-workflow.yml index c25a5de..760a5b3 100644 --- a/.github/workflows/release-QA-workflow.yml +++ b/.github/workflows/release-QA-workflow.yml @@ -10,7 +10,7 @@ jobs: Check-If-ReleaseNotes-Pushed: runs-on: - self-hosted - - segment-android-mini-mac-runner + # - segment-android-mini-mac-runner outputs: answer: ${{ steps.filter.outputs.releasenotesfile }} steps: From 5991c57bfdb7ffc2ae3548300ec3757531c32a5d Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 30 Apr 2023 17:22:45 +0300 Subject: [PATCH 36/44] removed labels --- .github/workflows/prepare-for-QA-release.yml | 2 +- .github/workflows/prepare-for-release-workflow.yml | 2 +- .github/workflows/release-production-workflow.yml | 2 +- .github/workflows/unit-tests-workflow.yml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index e60cce0..961dd99 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -8,7 +8,7 @@ jobs: name: Pre Release runs-on: - self-hosted - - segment-android-mini-mac-runner + # - segment-android-mini-mac-runner steps: - name: Checkout diff --git a/.github/workflows/prepare-for-release-workflow.yml b/.github/workflows/prepare-for-release-workflow.yml index 34108fd..3bd5d63 100644 --- a/.github/workflows/prepare-for-release-workflow.yml +++ b/.github/workflows/prepare-for-release-workflow.yml @@ -14,7 +14,7 @@ jobs: name: Prepare for production after testing the plugin runs-on: - self-hosted - - segment-android-mini-mac-runner + # - segment-android-mini-mac-runner steps: - name: Checkout uses: actions/checkout@v3 diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index ebb7e7e..5d4603a 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -13,7 +13,7 @@ jobs: if: github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/') runs-on: - self-hosted - - segment-android-mini-mac-runner + # - segment-android-mini-mac-runner steps: - name: Checkout uses: actions/checkout@v3 diff --git a/.github/workflows/unit-tests-workflow.yml b/.github/workflows/unit-tests-workflow.yml index e9cf866..6cc6fd4 100644 --- a/.github/workflows/unit-tests-workflow.yml +++ b/.github/workflows/unit-tests-workflow.yml @@ -9,7 +9,7 @@ jobs: Tests: runs-on: - self-hosted - - segment-android-mini-mac-runner + # - segment-android-mini-mac-runner steps: - uses: actions/checkout@v2 - name: Set up JDK From 96cabd57fbabd1db79484b7f784926267aa6a58f Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 30 Apr 2023 17:47:14 +0300 Subject: [PATCH 37/44] yaml chnages --- .github/bash_scripts/release.sh | 6 +++++- .github/workflows/prepare-for-QA-release.yml | 2 +- .github/workflows/prepare-for-release-workflow.yml | 1 - .github/workflows/release-QA-workflow.yml | 3 ++- .github/workflows/release-production-workflow.yml | 2 +- .github/workflows/unit-tests-workflow.yml | 1 - 6 files changed, 9 insertions(+), 6 deletions(-) diff --git a/.github/bash_scripts/release.sh b/.github/bash_scripts/release.sh index f84d7af..31ca6a7 100644 --- a/.github/bash_scripts/release.sh +++ b/.github/bash_scripts/release.sh @@ -7,4 +7,8 @@ NEW_VERSION_RELEASE_NOTES=$(cat "releasenotes.$releaseversion") NEW_VERSION_SECTION="### $releaseversion\n$NEW_VERSION_RELEASE_NOTES\n\n" echo -e "$NEW_VERSION_SECTION$(cat RELEASENOTES.md)" > RELEASENOTES.md -rm -r "releasenotes.$releaseversion" \ No newline at end of file +rm -r "releasenotes.$releaseversion" + +sed -E -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+).*/VERSION_NAME=$appsflyerversion/g" gradle.properties + +sed -E -i '' "s/(POM_ARTIFACT_ID=.*)-beta/\1/g" gradle.properties \ No newline at end of file diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index 961dd99..aa249fe 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -8,7 +8,6 @@ jobs: name: Pre Release runs-on: - self-hosted - # - segment-android-mini-mac-runner steps: - name: Checkout @@ -44,6 +43,7 @@ jobs: payload: | { "appsflyer_version": "${{env.PLUGIN_VERSION}}" + "appsflyer_version": "QA" } env: SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} diff --git a/.github/workflows/prepare-for-release-workflow.yml b/.github/workflows/prepare-for-release-workflow.yml index 3bd5d63..ce1debd 100644 --- a/.github/workflows/prepare-for-release-workflow.yml +++ b/.github/workflows/prepare-for-release-workflow.yml @@ -14,7 +14,6 @@ jobs: name: Prepare for production after testing the plugin runs-on: - self-hosted - # - segment-android-mini-mac-runner steps: - name: Checkout uses: actions/checkout@v3 diff --git a/.github/workflows/release-QA-workflow.yml b/.github/workflows/release-QA-workflow.yml index 760a5b3..f7af368 100644 --- a/.github/workflows/release-QA-workflow.yml +++ b/.github/workflows/release-QA-workflow.yml @@ -10,7 +10,6 @@ jobs: Check-If-ReleaseNotes-Pushed: runs-on: - self-hosted - # - segment-android-mini-mac-runner outputs: answer: ${{ steps.filter.outputs.releasenotesfile }} steps: @@ -26,8 +25,10 @@ jobs: needs: Check-If-ReleaseNotes-Pushed if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' uses: ./.github/workflows/unit-tests-workflow.yml + secrets: inherit Deploy-Locally-To-QA: needs: [Run-Unit-Tests,Check-If-ReleaseNotes-Pushed] if: needs.Check-If-ReleaseNotes-Pushed.outputs.answer == 'false' uses: ./.github/workflows/prepare-for-QA-release.yml + secrets: inherit diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index 5d4603a..3637819 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -13,7 +13,6 @@ jobs: if: github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/') runs-on: - self-hosted - # - segment-android-mini-mac-runner steps: - name: Checkout uses: actions/checkout@v3 @@ -63,6 +62,7 @@ jobs: payload: | { "appsflyer_version": "${{env.PLUGIN_VERSION}}" + "appsflyer_version": "Production" } env: SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} \ No newline at end of file diff --git a/.github/workflows/unit-tests-workflow.yml b/.github/workflows/unit-tests-workflow.yml index 6cc6fd4..bcc35e6 100644 --- a/.github/workflows/unit-tests-workflow.yml +++ b/.github/workflows/unit-tests-workflow.yml @@ -9,7 +9,6 @@ jobs: Tests: runs-on: - self-hosted - # - segment-android-mini-mac-runner steps: - uses: actions/checkout@v2 - name: Set up JDK From 2d6abfb4723e99a4d1c01d7e89f93265cbb663f2 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 30 Apr 2023 17:49:13 +0300 Subject: [PATCH 38/44] typo of copying --- .github/bash_scripts/release.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/bash_scripts/release.sh b/.github/bash_scripts/release.sh index 31ca6a7..7145aa5 100644 --- a/.github/bash_scripts/release.sh +++ b/.github/bash_scripts/release.sh @@ -9,6 +9,6 @@ echo -e "$NEW_VERSION_SECTION$(cat RELEASENOTES.md)" > RELEASENOTES.md rm -r "releasenotes.$releaseversion" -sed -E -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+).*/VERSION_NAME=$appsflyerversion/g" gradle.properties +sed -E -i '' "s/VERSION_NAME=([0-9]+\.[0-9]+\.[0-9]+).*/VERSION_NAME=$releaseversion/g" gradle.properties sed -E -i '' "s/(POM_ARTIFACT_ID=.*)-beta/\1/g" gradle.properties \ No newline at end of file From 8677cfa8872c4d32e1691c8947bf12230be2727e Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Sun, 30 Apr 2023 17:56:09 +0300 Subject: [PATCH 39/44] variable name for slack integration --- .github/workflows/prepare-for-QA-release.yml | 2 +- .github/workflows/release-production-workflow.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index aa249fe..c79d096 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -43,7 +43,7 @@ jobs: payload: | { "appsflyer_version": "${{env.PLUGIN_VERSION}}" - "appsflyer_version": "QA" + "environment": "QA" } env: SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index 3637819..cf2a785 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -62,7 +62,7 @@ jobs: payload: | { "appsflyer_version": "${{env.PLUGIN_VERSION}}" - "appsflyer_version": "Production" + "environment": "Production" } env: SLACK_WEBHOOK_URL: ${{ secrets.CI_SLACK_WEBHOOK_URL }} \ No newline at end of file From 8a7bd435b48b6fb59c276471b994e59a60cf719a Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 1 May 2023 15:25:36 +0300 Subject: [PATCH 40/44] last commit of ci flows after Paz's MR --- .github/workflows/prepare-for-QA-release.yml | 4 ++-- .github/workflows/prepare-for-release-workflow.yml | 4 ++-- .github/workflows/release-production-workflow.yml | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index c79d096..80b1045 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -11,7 +11,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Determine release tag and release branch run: | TAG=$(echo "${{github.ref_name}}" | grep -Eo '[0-9]+.[0-9]+.[0-9]+') @@ -25,7 +25,7 @@ jobs: with: author_name: Moris Gateno author_email: moris.gateno@appsflyer.com - message: 'Commited from github action - prepaing the repo for QA locally.' + message: 'Commited from github action - prepaing the repo for QA.' add: '.' - name: Set up JDK uses: actions/setup-java@v1 diff --git a/.github/workflows/prepare-for-release-workflow.yml b/.github/workflows/prepare-for-release-workflow.yml index ce1debd..a653625 100644 --- a/.github/workflows/prepare-for-release-workflow.yml +++ b/.github/workflows/prepare-for-release-workflow.yml @@ -5,8 +5,8 @@ on: types: - opened branches: - # - 'master' - - 'dev/add-release-workflow' + - 'master' +# - 'dev/add-release-workflow' jobs: Prepare-Plugin-For-Production: diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index cf2a785..fdba778 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -5,8 +5,8 @@ on: types: - closed branches: - # - 'master' - - 'dev/add-release-workflow' + - 'master' +# - 'dev/add-release-workflow' jobs: Deploy-To-Production: From 387790ed045d211e2e0db7bf9ddd311e1b881fb0 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 1 May 2023 15:45:23 +0300 Subject: [PATCH 41/44] syntax error --- .github/workflows/prepare-for-QA-release.yml | 2 +- .github/workflows/release-production-workflow.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/prepare-for-QA-release.yml b/.github/workflows/prepare-for-QA-release.yml index 80b1045..edfcfea 100644 --- a/.github/workflows/prepare-for-QA-release.yml +++ b/.github/workflows/prepare-for-QA-release.yml @@ -42,7 +42,7 @@ jobs: with: payload: | { - "appsflyer_version": "${{env.PLUGIN_VERSION}}" + "appsflyer_version": "${{env.PLUGIN_VERSION}}", "environment": "QA" } env: diff --git a/.github/workflows/release-production-workflow.yml b/.github/workflows/release-production-workflow.yml index fdba778..e19e5d4 100644 --- a/.github/workflows/release-production-workflow.yml +++ b/.github/workflows/release-production-workflow.yml @@ -61,7 +61,7 @@ jobs: with: payload: | { - "appsflyer_version": "${{env.PLUGIN_VERSION}}" + "appsflyer_version": "${{env.PLUGIN_VERSION}}", "environment": "Production" } env: From d4bcea3e10e79f8141d16686c18fdeb0b5d0dd30 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 1 May 2023 15:54:37 +0300 Subject: [PATCH 42/44] Commited from github action - prepaing the repo for QA. --- Readme.md | 4 ++-- app/build.gradle | 4 ++-- .../integrations/appsflyer/AppsflyerIntegration.java | 4 ++-- gradle.properties | 8 ++++---- releasenotes.6.10.3 | 0 segmenttestapp/build.gradle | 4 ++-- 6 files changed, 12 insertions(+), 12 deletions(-) create mode 100644 releasenotes.6.10.3 diff --git a/Readme.md b/Readme.md index b9037bf..8dd7ba6 100644 --- a/Readme.md +++ b/Readme.md @@ -21,7 +21,7 @@ You can track installs, updates and sessions and also track additional in-app ev --- -Built with AppsFlyer Android SDK `v6.10.2` +Built with AppsFlyer Android SDK `v6.10.3` ## Table of content @@ -95,7 +95,7 @@ And to start the AppsFlyer SDK, use `void startAppsFlyer(Context context)` API. Add the AppsFlyer Segment Integration dependency to your app `build.gradle` file. ```java -implementation 'com.appsflyer:segment-android-integration:6.10.2' +implementation 'com.appsflyer:segment-android-integration:6.10.3' implementation 'com.android.installreferrer:installreferrer:2.1' ``` diff --git a/app/build.gradle b/app/build.gradle index 3991981..834e501 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -39,7 +39,7 @@ android { dependencies { implementation 'androidx.test.ext:junit:1.1.5' - implementation 'com.appsflyer:af-android-sdk:6.10.2' + implementation 'com.appsflyer:af-android-sdk:6.10.3' compileOnly 'com.android.installreferrer:installreferrer:2.1' compileOnly 'com.segment.analytics.android:analytics:4.+' testImplementation 'androidx.test:core:1.4.0' @@ -59,4 +59,4 @@ tasks.withType(Test) { } } -apply from:file("publish.gradle") \ No newline at end of file +apply from:file("publish.gradle") diff --git a/app/src/main/java/com/segment/analytics/android/integrations/appsflyer/AppsflyerIntegration.java b/app/src/main/java/com/segment/analytics/android/integrations/appsflyer/AppsflyerIntegration.java index d3bb361..f406325 100644 --- a/app/src/main/java/com/segment/analytics/android/integrations/appsflyer/AppsflyerIntegration.java +++ b/app/src/main/java/com/segment/analytics/android/integrations/appsflyer/AppsflyerIntegration.java @@ -98,7 +98,7 @@ public Integration create(ValueMap settings, Analytics analytics) listener = new ConversionListener(analytics); } - AppsFlyerLib.getInstance().setPluginInfo(new PluginInfo(Plugin.SEGMENT,"6.10.2")); + AppsFlyerLib.getInstance().setPluginInfo(new PluginInfo(Plugin.SEGMENT,"6.10.3")); afLib.setDebugLog(logger.logLevel != Analytics.LogLevel.NONE); afLib.init(devKey, listener, application.getApplicationContext()); if (deepLinkListener != null) @@ -321,4 +321,4 @@ private Context getContext() { -} \ No newline at end of file +} diff --git a/gradle.properties b/gradle.properties index 05b1498..618495b 100644 --- a/gradle.properties +++ b/gradle.properties @@ -19,9 +19,9 @@ GROUP=com.appsflyer -VERSION_CODE=12 -VERSION_NAME=6.10.2 -POM_ARTIFACT_ID=segment-android-integration +VERSION_CODE=13 +VERSION_NAME=6.10.3-rc1 +POM_ARTIFACT_ID=segment-android-integration-beta POM_PACKAGING=aar POM_NAME=AppsFlyer Integration @@ -40,4 +40,4 @@ POM_DEVELOPER_ID=appsflyer POM_DEVELOPER_NAME=AppsFlyer, Inc. android.useAndroidX=true -android.enableJetifier=true \ No newline at end of file +android.enableJetifier=true diff --git a/releasenotes.6.10.3 b/releasenotes.6.10.3 new file mode 100644 index 0000000..e69de29 diff --git a/segmenttestapp/build.gradle b/segmenttestapp/build.gradle index 0199a04..0344169 100644 --- a/segmenttestapp/build.gradle +++ b/segmenttestapp/build.gradle @@ -27,7 +27,7 @@ dependencies { implementation project(path: ':app') testImplementation 'junit:junit:4.12' implementation 'com.android.support:appcompat-v7:28.0.0' - implementation 'com.appsflyer:af-android-sdk:6.10.2' + implementation 'com.appsflyer:af-android-sdk:6.10.3' implementation 'com.segment.analytics.android:analytics:4.+' implementation 'com.android.installreferrer:installreferrer:2.1' -} \ No newline at end of file +} From 280fba6e94c856345ba96afa4cc22b310e63b7c1 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 1 May 2023 15:58:32 +0300 Subject: [PATCH 43/44] added releasenotes --- releasenotes.6.10.3 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/releasenotes.6.10.3 b/releasenotes.6.10.3 index e69de29..0792a85 100644 --- a/releasenotes.6.10.3 +++ b/releasenotes.6.10.3 @@ -0,0 +1,2 @@ +* Update Android SDK to v6.10.1 +* Added CI-CD pipeline \ No newline at end of file From 67b419a148c677b0073a179b7b0ba586f2365ae0 Mon Sep 17 00:00:00 2001 From: Moris Gateno Date: Mon, 1 May 2023 16:35:34 +0300 Subject: [PATCH 44/44] Commited from github action - prepaing the repo for production. --- RELEASENOTES.md | 4 ++++ gradle.properties | 4 ++-- releasenotes.6.10.3 | 2 -- 3 files changed, 6 insertions(+), 4 deletions(-) delete mode 100644 releasenotes.6.10.3 diff --git a/RELEASENOTES.md b/RELEASENOTES.md index 5558503..8198683 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -1,3 +1,7 @@ +### 6.10.3 +* * Update Android SDK to v6.10.1 +* * Added CI-CD pipeline + ### 6.10.2 * Update Android SDK to v6.10.2 * Added Platform Extension v2 call. diff --git a/gradle.properties b/gradle.properties index 618495b..b4521a0 100644 --- a/gradle.properties +++ b/gradle.properties @@ -20,8 +20,8 @@ GROUP=com.appsflyer VERSION_CODE=13 -VERSION_NAME=6.10.3-rc1 -POM_ARTIFACT_ID=segment-android-integration-beta +VERSION_NAME=6.10.3 +POM_ARTIFACT_ID=segment-android-integration POM_PACKAGING=aar POM_NAME=AppsFlyer Integration diff --git a/releasenotes.6.10.3 b/releasenotes.6.10.3 deleted file mode 100644 index 0792a85..0000000 --- a/releasenotes.6.10.3 +++ /dev/null @@ -1,2 +0,0 @@ -* Update Android SDK to v6.10.1 -* Added CI-CD pipeline \ No newline at end of file