Skip to content

.github/workflows/build-and-deploy-main.yml #486

.github/workflows/build-and-deploy-main.yml

.github/workflows/build-and-deploy-main.yml #486

on:
push:
branches:
- master
- main
schedule:
# * is a special character in YAML so you have to quote this string
- cron: '0 0 * * *'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Configure GPG Key
run: echo -n "$PGP_KEY" | gpg --batch --import
env:
PGP_KEY: ${{ secrets.PGP_KEY }}
- name: Set up JDK 21 ☕
uses: actions/setup-java@v4
with:
java-version: 21
distribution: 'temurin'
- name: Set up Maven
uses: stCarolas/setup-maven@v5
with:
maven-version: 3.9.6
- name: Build with Maven 🏗️
run: mvn -B clean verify -DskipTests -Dgpg.keyname=B65A772A26C6CFCD2ABEB352ACCF6EF34A59AB7C -Dgpg.passphrase="$PGP_PASSPHRASE"
env:
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}
- name: Deploy to GH-pages 🚀
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: repository/target/repository # The folder the action should deploy.