feat: Enable and configure Dependabot 🤖 (#2) #2
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
# This workflow will build a Java project with Gradle | |
name: Run release build from tag | |
on: | |
push: | |
tags: | |
- '*' | |
jobs: | |
release: | |
environment: CIRelease | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: 17 | |
distribution: temurin | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
submodules: true | |
- run: git fetch --all --tag | |
- name: Create .gradle dir | |
run: mkdir -p $HOME/.gradle | |
- id: install-secret-key | |
name: Install gpg secret key | |
env: | |
SIGNINGFILE: ${{ secrets.SIGNINGFILE }} | |
run: | | |
cat <(echo -e "${{ secrets.SIGNINGFILE }}") | gpg --batch --import | |
gpg --list-secret-keys --keyid-format LONG | |
- id: export-gpg-file | |
name: Export gpg file | |
env: | |
SIGNINGKEYID: ${{ secrets.SIGNINGKEYID }} | |
SIGNINGPASSWORD: ${{ secrets.SIGNINGPASSWORD }} | |
run: | | |
gpg --batch --passphrase="$SIGNINGPASSWORD" --pinentry-mode loopback --export-secret-keys $SIGNINGKEYID > $HOME/.gradle/secrets.gpg | |
- name: Create gradle properties | |
env: | |
SIGNINGKEYID: ${{ secrets.SIGNINGKEYID }} | |
SIGNINGPASSWORD: ${{ secrets.SIGNINGPASSWORD }} | |
SONATYPEPASSWORD: ${{ secrets.SONATYPEPASSWORD }} | |
SONATYPEUSER: ${{ secrets.SONATYPEUSER }} | |
run: echo -e "signing.keyId=$SIGNINGKEYID\nsigning.password=$SIGNINGPASSWORD\nsigning.secretKeyRingFile=$HOME/.gradle/secrets.gpg\nsonatypeUsername=$SONATYPEUSER\nsonatypePassword=$SONATYPEPASSWORD" > $HOME/.gradle/gradle.properties | |
- name: Run gradle release | |
env: | |
GRADLE_OPTS: "-Dorg.gradle.daemon=true" | |
run: ./gradlew -PrunOnCI=true build test :publishIntershopMvnPublicationToMavenRepository -s | |
- name: Publish Unit Test Results | |
uses: EnricoMi/publish-unit-test-result-action/composite@v2 | |
if: always() | |
with: | |
files: build/test-results/**/*.xml | |
- name: Post Build | |
run: rm -f $HOME/.gradle/gradle.properties |