Skip to content

8.2.1

8.2.1 #43

Workflow file for this run

name: Publish
on:
release:
types: [created]
jobs:
publish:
runs-on: ${{ vars.LINUX }}
timeout-minutes: 10
env:
MAILOSAUR_BASE_URL: https://mailosaur.com/
MAILOSAUR_SMTP_HOST: mailosaur.net
MAILOSAUR_SMTP_PORT: 2525
MAILOSAUR_API_KEY: ${{ secrets.MAILOSAUR_API_KEY }}
MAILOSAUR_SERVER: ${{ secrets.MAILOSAUR_SERVER }}
MAILOSAUR_VERIFIED_DOMAIN: ${{ secrets.MAILOSAUR_VERIFIED_DOMAIN }}
MAILOSAUR_PREVIEWS_SERVER: ${{ secrets.MAILOSAUR_PREVIEWS_SERVER }}
steps:
- uses: actions/checkout@v2
- name: Set up Java
uses: actions/setup-java@v4
with:
java-version: ${{ vars.JAVA_VERSION }}
distribution: temurin
server-id: central
server-username: ${{ secrets.MAVEN_CENTRAL_USERNAME }}
server-password: ${{ secrets.MAVEN_CENTRAL_PASSWORD }}
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase
- name: Version
run: |
version=`git describe --abbrev=0 --tags` &&
sed -i s/\[0-9]\.\[0-9]\.\[0-9]/$version/ src/main/java/com/mailosaur/MailosaurClient.java &&
mvn versions:set -DnewVersion=$version
- name: Publish
run: |
mvn deploy
env:
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}
- name: Notify on Failure
uses: skitionek/notify-microsoft-teams@master
if: ${{ failure() }}
with:
webhook_url: ${{ secrets.TEAMS_BUILDS_WEBHOOK }}
needs: ${{ toJson(needs) }}
job: ${{ toJson(job) }}
overwrite: "{ title: `${workflow} failed for ${repository.name}` }"