Update Spigot to 1.21 #245
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CyberAPI | |
on: | |
push: | |
branches: ["main"] | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
java: [17] | |
fail-fast: true | |
permissions: | |
contents: write | |
packages: write | |
steps: | |
- name: Actions Checkout | |
uses: actions/[email protected] | |
- name: Set up JDK ${{ matrix.java }} | |
uses: actions/[email protected] | |
with: | |
java-version: ${{ matrix.java }} | |
distribution: 'temurin' | |
cache: 'gradle' | |
- name: Validate Gradle Wrapper | |
uses: gradle/[email protected] | |
- name: Set Gradle Version | |
uses: gradle/[email protected] | |
with: | |
gradle-version: release-candidate | |
- name: Build Gradle | |
uses: gradle/[email protected] | |
with: | |
arguments: shadowJar --stacktrace | |
- name: Release CyberAPI to Nexus | |
uses: gradle/gradle-build-action@bd5760595778326ba7f1441bcf7e88b49de61a25 | |
with: | |
arguments: publish | |
env: | |
NEXUS_USERNAME: ${{ secrets.NEXUS_USERNAME }} | |
NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }} | |
- name: Read Version | |
id: version | |
uses: christian-draeger/[email protected] | |
with: | |
path: 'build/common-build.properties' | |
property: 'version' | |
- name: Read Build Number | |
id: build | |
uses: christian-draeger/[email protected] | |
with: | |
path: 'build/common-build.properties' | |
property: 'buildNumber' | |
- name: Release CyberAPI to GitHub | |
uses: ncipollo/[email protected] | |
with: | |
artifacts: "build/artifacts/*.jar" | |
name: "Build #${{ steps.build.outputs.value }}" | |
tag: ${{ steps.build.outputs.value }} | |
commit: main | |
body: | | |
**Related Commit:** | |
``` | |
${{ github.event.head_commit.message }} | |
``` | |
[click here to view!](https://github.com/${{ github.event.repository.full_name }}/commit/${{ github.event.head_commit.id }}) | |
<br> | |
**It is not recommended you download the files from here, please use the [README Installation Guide](https://github.com/${{ github.event.repository.full_name }}#how-to-install-and-use)** | |
If you really want to though, you can [click here](https://jitpack.io/#${{ github.event.repository.full_name }}/${{ steps.build.outputs.value }}) for the JitPack link! | |
generateReleaseNotes: true |