@@ -9,9 +9,11 @@ jobs:
|
||||
build:
|
||||
name: Build with Maven
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
contents: write
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v5
|
||||
uses: actions/checkout@v6
|
||||
|
||||
- name: Set up JDK 25 and enable Maven cache
|
||||
uses: actions/setup-java@v5
|
||||
@@ -28,8 +30,20 @@ jobs:
|
||||
- name: Build and package with Maven
|
||||
run: mvn -B package
|
||||
|
||||
- name: Determine version
|
||||
id: set-version
|
||||
shell: bash
|
||||
run: |
|
||||
VERSION=${GITHUB_REF#refs/tags/ver/}
|
||||
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
|
||||
|
||||
- name: Upload built artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: maven-artifacts
|
||||
path: target/spigot/*.jar
|
||||
path: target/spigot/*.jar
|
||||
|
||||
- uses: ncipollo/release-action@v1
|
||||
with:
|
||||
name: "${{ steps.set-version.outputs.version }} Release"
|
||||
artifacts: "target/spigot/*.jar"
|
||||
|
||||
Reference in New Issue
Block a user