2022-01-26 15:11:35 +00:00
|
|
|
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
|
|
|
|
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
|
|
|
|
|
|
|
|
name: Build & Tests
|
|
|
|
|
|
|
|
on:
|
|
|
|
# 支持手动触发构建
|
|
|
|
workflow_dispatch:
|
2022-12-17 18:57:08 +00:00
|
|
|
pull_request:
|
2022-01-26 15:11:35 +00:00
|
|
|
push:
|
2022-12-17 18:57:08 +00:00
|
|
|
paths-ignore:
|
|
|
|
- ".github/**"
|
|
|
|
- "README.md"
|
|
|
|
- "LICENCE"
|
2022-01-26 15:11:35 +00:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: "Set up JDK"
|
|
|
|
uses: actions/setup-java@v2
|
|
|
|
with:
|
|
|
|
java-version: '11'
|
|
|
|
distribution: 'adopt'
|
|
|
|
- name: "Package"
|
2022-12-17 18:57:08 +00:00
|
|
|
run: mvn -B package --file pom.xml -Dgpg.skip
|
2022-12-17 19:07:06 +00:00
|
|
|
|
|
|
|
- name: "Upload artifacts"
|
|
|
|
uses: actions/upload-artifact@v2
|
|
|
|
with:
|
|
|
|
name: artifacts
|
|
|
|
path: "**/target/"
|
|
|
|
|
|
|
|
- name: "Upload assets"
|
2022-01-26 15:11:35 +00:00
|
|
|
uses: actions/upload-artifact@v2
|
|
|
|
with:
|
2022-12-17 19:07:06 +00:00
|
|
|
name: assets
|
|
|
|
path: ".asset/"
|