Maven publication renamed. #146
Workflow file for this run
This file contains hidden or 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: Android CI | |
on: | |
push: | |
# branches: [ master ] | |
paths-ignore: | |
- '**/README.md' | |
- 'screenshots/**' | |
- '.gitignore' | |
- '.idea/**' | |
- '.run/**' | |
tags: | |
- "[0-9]+.[0-9]+.[0-9]+" | |
jobs: | |
build: | |
name: π Build Android Library | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
# https://github.com/actions/checkout | |
- name: π Get latest code | |
uses: actions/checkout@v4 | |
# https://github.com/actions/setup-java | |
- name: β Set up JDK | |
uses: actions/setup-java@v4 | |
with: | |
architecture: x64 | |
distribution: corretto | |
java-version: '17' | |
# https://github.com/gradle/actions/blob/main/docs/setup-gradle.md | |
- name: π Setup Gradle | |
uses: gradle/actions/setup-gradle@v4 | |
with: | |
cache-encryption-key: ${{ SECRETS.GRADLE_ENCRYPTION_KEY }} | |
cache-cleanup: always | |
# Check out the GPR Maintenance plugin source code. | |
# This will replicate the local directory structure. | |
- name: Check out GPR Maintenance plugin | |
run: git clone https://github.com/syslogic/gpr-maintenance-gradle-plugin.git ./buildSrc | |
- name: π chmod +x | |
run: chmod +x ./buildSrc/gradlew ./gradlew | |
- name: π Publish AAR to GPR | |
env: | |
GITHUB_ACTOR: ${{ GITHUB.REPOSITORY_OWNER }} | |
GITHUB_TOKEN: ${{ SECRETS.GITHUB_TOKEN }} | |
run: | | |
./gradlew --max-workers=2 :androidx-github:lint :androidx-github:publishLibraryPublicationToGitHubPackagesRepository | |
ls -la ./library/build/outputs/aar | grep aar | |
# https://github.com/actions/upload-artifact | |
- name: π¦ Retain Artifacts (AAR) | |
id: retain-library-aar | |
uses: actions/upload-artifact@v4 | |
with: | |
name: androidx-github | |
path: ./library/build/outputs/aar/*.aar | |
retention-days: 14 | |
# https://github.com/actions/upload-artifact | |
- name: π¦ Retain Artifacts (Lint Results) | |
id: retain-lint-results | |
uses: actions/upload-artifact@v4 | |
with: | |
name: androidx-github-lint | |
path: ./library/build/reports/* | |
retention-days: 14 | |
# - name: π Publish JAR to GPR | |
# env: | |
# GITHUB_ACTOR: ${{ GITHUB.REPOSITORY_OWNER }} | |
# GITHUB_TOKEN: ${{ SECRETS.GITHUB_TOKEN }} | |
# run: | | |
# # PUT -> HTTP 403 | |
# # ./gradlew --max-workers=2 :buildSrc:publishPluginPublicationToGitHubPackagesRepository | |
# ./gradlew --max-workers=2 :buildSrc:build | |
# ls -la ./buildSrc/build/libs | grep jar | |
# - name: π¦ Retain Artifacts (JAR) | |
# id: retain-library-jar | |
# uses: actions/upload-artifact@v4 | |
# with: | |
# name: gpr-maintenance-gradle-plugin | |
# path: ./buildSrc/build/libs/*.jar | |
# retention-days: 14 |