-
Notifications
You must be signed in to change notification settings - Fork 20
71 lines (61 loc) · 2.28 KB
/
release-workflow.yml
File metadata and controls
71 lines (61 loc) · 2.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
name: Release RC and Update Docs
env:
SONATYPE_USERNAME: ${{ secrets.SONATYPE_TOKEN_USER }}
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_TOKEN_USER_PASSWORD }}
MAVEN_QA_USER: github
MAVEN_QA_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}
mavenSigningKeyId: ${{ secrets.MAVEN_ANDROID_SIGNING_KEY }}
mavenSigningKeyRingFileEncoded: ${{ secrets.MAVEN_ANDROID_GPG_KEY }}
mavenSigningKeyPassword: ${{ secrets.MAVEN_ANDROID_SIGNING_PASSWORD }}
on:
workflow_dispatch:
inputs:
rc_version:
description: 'SDK version this workflow run will release. Specify <major.minor.patch> e.g. 7.1.2. It will use the branch "release/<version>".'
required: true
permissions:
contents: write
jobs:
release-to-maven-central:
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Validate access to version data service
uses: embrace-io/public-actions/upload-sdk-version@f4229398f257b24dbbe8b873f78e719f9af6cbbb
with:
platform: 'android'
version: ${{ inputs.rc_version }}
dryRun: true
uploadUrl: ${{ vars.SDK_VERSION_URL }}
env:
SDK_VERSION_TOKEN: ${{ secrets.SDK_VERSION_TOKEN }}
- name: Checkout SDK
uses: actions/checkout@v4
with:
ref: release/${{ inputs.rc_version }}
fetch-depth: 0
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: 17
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v4
- name: Release to Maven Central
run: |
./gradlew findSonatypeStagingRepository releaseSonatypeStagingRepository -Dorg.gradle.parallel=false --no-build-cache --no-configuration-cache --stacktrace
- name: Record SDK Version History
uses: embrace-io/public-actions/upload-sdk-version@f4229398f257b24dbbe8b873f78e719f9af6cbbb
with:
platform: 'android'
version: ${{ inputs.rc_version }}
dryRun: false
uploadUrl: ${{ vars.SDK_VERSION_URL }}
env:
SDK_VERSION_TOKEN: ${{ secrets.SDK_VERSION_TOKEN }}
publish-api-docs:
name: Publish API Docs to GitHub Pages
uses: ./.github/workflows/publish-api-docs.yml
secrets: inherit
with:
rc_version: ${{ inputs.rc_version }}