Skip to content

Commit 197e6ba

Browse files
Added publish action
1 parent d783a01 commit 197e6ba

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

.github/workflows/publish.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Publish
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
version:
7+
description: "Release version"
8+
required: true
9+
jobs:
10+
release:
11+
name: Release
12+
runs-on: ubuntu-18.04
13+
steps:
14+
- uses: actions/checkout@v2
15+
with:
16+
fetch-depth: 0
17+
18+
- name: Set up Java
19+
uses: actions/setup-java@v1
20+
with:
21+
java-version: 11
22+
23+
- uses: actions/cache@v2
24+
with:
25+
path: ~/.m2/repository
26+
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
27+
restore-keys: |
28+
${{ runner.os }}-maven-
29+
30+
- name: Set release version
31+
run: |
32+
VERSION=${{ github.event.inputs.version }}
33+
./mvnw versions:set -DnewVersion=$VERSION
34+
35+
- name: Build
36+
run: ./mvnw --no-transfer-progress -B --file pom.xml process-resources
37+
38+
- name: Deploy
39+
uses: peaceiris/actions-gh-pages@v3
40+
with:
41+
github_token: ${{ secrets.GITHUB_TOKEN }}
42+
publish_dir: ./target/generated-docs

0 commit comments

Comments
 (0)