Release #55
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
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
# Copyright 2020 Adobe Systems Incorporated | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software | |
# distributed under the License is distributed on an "AS IS" BASIS, | |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
# See the License for the specific language governing permissions and | |
# limitations under the License. | |
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
name: Release | |
# Run workflow on commits to default branch | |
on: workflow_dispatch | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
# Check out Git repository | |
- uses: actions/checkout@v2 | |
# Set up environment with Java and Maven | |
- name: Set up JDK | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 8 | |
# Set up dependency cache | |
- name: Cache local Maven repository | |
uses: actions/cache@v2 | |
with: | |
path: ~/.m2/repository | |
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | |
restore-keys: | | |
${{ runner.os }}-maven- | |
# Import GPG key from env variable into keychain | |
- name: Import GPG key | |
env: | |
GPG_SECRET_KEYS: ${{ secrets.GPG_SECRET_KEYS }} | |
GPG_OWNERTRUST: ${{ secrets.GPG_OWNERTRUST }} | |
run: | | |
echo $GPG_SECRET_KEYS | base64 --decode | gpg --import --no-tty --batch --yes | |
echo $GPG_OWNERTRUST | base64 --decode | gpg --import-ownertrust --no-tty --batch --yes | |
- name: Configure git user for release commits | |
env: | |
X_GITHUB_USERNAME: ${{ secrets.ADOBE_BOT_GITHUB_USERNAME }} | |
run: | | |
git config user.email "Grp-opensourceoffice@adobe.com" | |
git config user.name "${X_GITHUB_USERNAME}" | |
# Deploy to OSSRH, which will automatically release to Central Repository | |
- name: Release to Central Repository | |
env: | |
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} | |
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} | |
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} | |
X_GITHUB_USERNAME: ${{ secrets.ADOBE_BOT_GITHUB_USERNAME }} | |
X_GITHUB_PASSWORD: ${{ secrets.ADOBE_BOT_GITHUB_PASSWORD }} | |
run: mvn -B clean release:prepare release:perform -Prelease,ossrh,it-basic -s ./.github/workflows/settings.xml |