53 lines
1.0 KiB
YAML
53 lines
1.0 KiB
YAML
name: Build
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
paths-ignore:
|
|
- README.md
|
|
- .gitignore
|
|
- .gitattributes
|
|
- '**/.git/*'
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
paths-ignore:
|
|
- README.md
|
|
- .gitignore
|
|
- .gitattributes
|
|
- '**/*.md'
|
|
- '**/.git/*'
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
fetch-tags: true
|
|
|
|
- name: Setup JDK 21
|
|
uses: actions/setup-java@v4
|
|
with:
|
|
java-version: '21'
|
|
distribution: 'temurin'
|
|
|
|
- name: Setup Gradle
|
|
uses: gradle/actions/setup-gradle@v4
|
|
|
|
- name: Grant execute permission to gradlew
|
|
run: chmod +x gradlew
|
|
|
|
- name: Build with Gradle
|
|
run: ./gradlew build
|
|
|
|
- name: Upload Build Artifact
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: main-build
|
|
path: build/libs/*.jar
|
|
|