Merge pull request #3115 from square/expose_public_swift_helpers #26
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: release | |
on: | |
push: | |
tags: | |
- '**' | |
env: | |
GRADLE_OPTS: "-Dorg.gradle.jvmargs=-Xmx4g -Dorg.gradle.daemon=false -Dkotlin.incremental=false" | |
jobs: | |
publish-artifacts: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-java@v4 | |
with: | |
distribution: 'zulu' | |
java-version: 19 | |
- name: Setup Xcode | |
uses: maxim-lobanov/setup-xcode@v1 | |
with: | |
xcode-version: latest-stable | |
# We set `SDKROOT` as a workaround for https://github.com/gradle/gradle/pull/29227 | |
- name: Upload Artifacts | |
run: | | |
SDKROOT=$(xcrun -sdk macosx --show-sdk-path) ./gradlew publish --stacktrace --warning-mode all --no-daemon | |
env: | |
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.SONATYPE_NEXUS_USERNAME }} | |
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.SONATYPE_NEXUS_PASSWORD }} | |
ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.ARTIFACT_SIGNING_PRIVATE_KEY }} | |
# We set `SDKROOT` as a workaround for https://github.com/gradle/gradle/pull/29227 | |
- name: Publish plugin to Gradle portal | |
run: | | |
SDKROOT=$(xcrun -sdk macosx --show-sdk-path) ./gradlew publishPluginToGradlePortalIfRelease --stacktrace --warning-mode all | |
env: | |
GRADLE_PUBLISH_KEY: ${{ secrets.GRADLE_PUBLISH_KEY }} | |
GRADLE_PUBLISH_SECRET: ${{ secrets.GRADLE_PUBLISH_SECRET }} | |
publish-website: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'zulu' | |
java-version: 19 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: 3.8 | |
- name: Prepare docs | |
run: .buildscript/prepare_mkdocs.sh | |
- name: Build mkdocs | |
run: | | |
pip3 install mkdocs-material mkdocs-macros-plugin | |
mkdocs build | |
- name: Restore 2.x docs | |
run: .buildscript/restore_v2_docs.sh | |
- name: Deploy docs | |
if: success() | |
uses: JamesIves/github-pages-deploy-action@releases/v3 | |
with: | |
GITHUB_TOKEN: ${{ secrets.GH_CLIPPY_TOKEN }} | |
BRANCH: gh-pages | |
FOLDER: site | |
SINGLE_COMMIT: true |