run publishToMavenLocal for ci #23
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: Build Example | |
| on: [ push, workflow_dispatch ] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| env: | |
| UBIQUE_POEDITOR_API_KEY: X | |
| steps: | |
| # Checkout repository | |
| - name: Checkout | |
| uses: actions/checkout@v4.1.1 | |
| # Setup JDK environment | |
| - name: Set up JDK | |
| uses: actions/setup-java@v4.3.0 | |
| with: | |
| distribution: 'zulu' | |
| java-version: '17' | |
| - name: Grant permission to execute | |
| run: chmod +x gradlew | |
| # Run the Gradle tasks | |
| - name: Dry run :poeditorPull | |
| run: ./gradlew :appexample:poeditorPull --dry-run | |
| - name: Dry run :poeditorAddTerm | |
| run: ./gradlew :appexample:poeditorAddTerm --dry-run | |
| publishToMavenLocal: | |
| runs-on: ubuntu-latest | |
| env: | |
| UBIQUE_POEDITOR_API_KEY: X | |
| steps: | |
| # Checkout repository | |
| - name: Checkout | |
| uses: actions/checkout@v4.1.1 | |
| # Setup JDK environment | |
| - name: Set up JDK | |
| uses: actions/setup-java@v4.3.0 | |
| with: | |
| distribution: 'zulu' | |
| java-version: '17' | |
| - name: Grant permission to execute | |
| run: chmod +x gradlew | |
| # Run the Gradle tasks | |
| - name: Run :plugin:publishToMavenLocal | |
| run: | | |
| echo "${{secrets.MAVEN_SIGNING_KEY_ARMOR_ASC}}" > ./signingkey.asc | |
| gpg --quiet --output $GITHUB_WORKSPACE/signingkey.gpg --dearmor ./signingkey.asc | |
| ./gradlew :poeditor:plugin:publishToMavenLocal -Psigning.secretKeyRingFile=$GITHUB_WORKSPACE/signingkey.gpg -Psigning.password='${{secrets.MAVEN_SIGNING_KEY_PASSPHRASE}}' -Psigning.keyId=${{secrets.MAVEN_SIGNING_KEY_ID}} -PmavenCentralUsername=${{secrets.MAVEN_CENTRAL_USERNAME}} -PmavenCentralPassword=${{secrets.MAVEN_CENTRAL_PASSWORD}} -PgithubRefName=${{ github.run_number }}-local --no-configuration-cache |