Rework actions to publish to Maven and Releases. Update README.md to reference Gitea maven.
release / build (21) (push) Failing after 11m5s
release / build (21) (push) Failing after 11m5s
This commit is contained in:
@@ -0,0 +1,39 @@
|
|||||||
|
name: release
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- "*"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
java: [
|
||||||
|
21, # Current Java LTS
|
||||||
|
]
|
||||||
|
runs-on: ubuntu-22.04
|
||||||
|
steps:
|
||||||
|
- name: checkout repository
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
- name: validate gradle wrapper
|
||||||
|
uses: gradle/wrapper-validation-action@v2
|
||||||
|
- name: setup jdk ${{ matrix.java }}
|
||||||
|
uses: actions/setup-java@v4
|
||||||
|
with:
|
||||||
|
java-version: ${{ matrix.java }}
|
||||||
|
distribution: "temurin"
|
||||||
|
- name: make gradle wrapper executable
|
||||||
|
run: chmod +x ./gradlew
|
||||||
|
- name: build
|
||||||
|
run: ./gradlew build
|
||||||
|
- name: publish maven
|
||||||
|
env:
|
||||||
|
MAVEN_TOKEN: "${{secrets.MAVEN_TOKEN}}"
|
||||||
|
run: ./gradlew publish
|
||||||
|
- name: publish release
|
||||||
|
uses: https://gitea.com/actions/release-action@main
|
||||||
|
with:
|
||||||
|
files: |-
|
||||||
|
build/libs/**
|
||||||
|
api_key: "${{secrets.RELEASE_TOKEN}}"
|
||||||
@@ -1,39 +0,0 @@
|
|||||||
# Automatically build the project and run any configured tests for every push
|
|
||||||
# and submitted pull request. This can help catch issues that only occur on
|
|
||||||
# certain platforms or Java versions, and provides a first line of defence
|
|
||||||
# against bad commits.
|
|
||||||
|
|
||||||
name: build
|
|
||||||
on: [pull_request, push]
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
strategy:
|
|
||||||
matrix:
|
|
||||||
# Use these Java versions
|
|
||||||
java: [
|
|
||||||
21, # Current Java LTS
|
|
||||||
]
|
|
||||||
runs-on: ubuntu-22.04
|
|
||||||
steps:
|
|
||||||
- name: checkout repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
- name: validate gradle wrapper
|
|
||||||
uses: gradle/wrapper-validation-action@v2
|
|
||||||
- name: setup jdk ${{ matrix.java }}
|
|
||||||
uses: actions/setup-java@v4
|
|
||||||
with:
|
|
||||||
java-version: ${{ matrix.java }}
|
|
||||||
distribution: 'microsoft'
|
|
||||||
- name: make gradle wrapper executable
|
|
||||||
run: chmod +x ./gradlew
|
|
||||||
- name: build
|
|
||||||
run: ./gradlew build
|
|
||||||
# - name: maven
|
|
||||||
# run: ./gradlew publish
|
|
||||||
- name: capture build artifacts
|
|
||||||
if: ${{ matrix.java == '21' }} # Only upload artifacts built from latest java
|
|
||||||
uses: christopherhx/gitea-upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: Artifacts
|
|
||||||
path: build/libs/
|
|
||||||
Reference in New Issue
Block a user