Switch to Java Build Essentials (#214) #36
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: Merge Pull Request | |
on: | |
push: | |
branches: | |
- main | |
- master | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: zulu | |
java-version: 21 | |
server-id: packagecloud | |
server-username: MAVEN_USERNAME | |
server-password: MAVEN_PASSWORD | |
- name: Publish package | |
run: mvn -B deploy | |
env: | |
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }} | |
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }} | |
- name: Get tag name | |
id: tagname | |
run: | | |
VERSION=$(cat VERSION.txt) | |
echo version: VERSION | |
echo "RELEASE_TAG=$VERSION" >> "$GITHUB_ENV" | |
- name: Show tag name | |
run: | | |
echo env: "${{ env.RELEASE_TAG }}" | |
- name: Create release | |
uses: actions/create-release@v1 | |
id: create_release | |
with: | |
draft: false | |
prerelease: false | |
release_name: ${{ env.RELEASE_TAG }} | |
tag_name: ${{ env.RELEASE_TAG }} | |
body_path: CHANGELOG.md | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |