Update build.yml

This commit is contained in:
Koopa 2025-01-31 20:46:22 -05:00
parent ec08413850
commit 7c2ca81ea2

View File

@ -36,15 +36,17 @@ jobs:
- name: Copy JAR to root - name: Copy JAR to root
run: | run: |
cp target/${{ env.PLUGIN_FILE }}-*.jar ./${{ env.PLUGIN_FILE }}.jar || exit 1 mkdir artifacts
cp target/${{ env.PLUGIN_FILE }}-*.jar ./artifacts/${{ env.PLUGIN_FILE }}.jar || exit 1
- name: Upload build artifacts - name: Upload build artifacts
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: ${{ env.PLUGIN_FILE }} name: ${{ env.PLUGIN_FILE }}
path: ${{ env.PLUGIN_FILE }}.jar path: artifacts/${{ env.PLUGIN_FILE }}.jar
compression-level: 0 compression-level: 0
retention-days: 5 retention-days: 5
if-no-files-found: error
- name: Send Discord Notification - name: Send Discord Notification
if: success() if: success()
@ -69,11 +71,18 @@ jobs:
uses: actions/download-artifact@v4 uses: actions/download-artifact@v4
with: with:
name: ${{ env.PLUGIN_FILE }} name: ${{ env.PLUGIN_FILE }}
path: ./
- name: Prepare Release Asset
run: |
ls -la
mv ${{ env.PLUGIN_FILE }}.jar NoBullying-${{ github.ref_name }}.jar
- name: Upload release artifacts - name: Upload release artifacts
uses: softprops/action-gh-release@v2 uses: softprops/action-gh-release@v2
with: with:
files: ${{ env.PLUGIN_FILE }}.jar files: NoBullying-${{ github.ref_name }}.jar
fail_on_unmatched_files: true
- name: Send Release Discord Notification - name: Send Release Discord Notification
if: success() if: success()