-
Notifications
You must be signed in to change notification settings - Fork 1
56 lines (49 loc) · 2.05 KB
/
upload-jar.yml
File metadata and controls
56 lines (49 loc) · 2.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: Upload Server JAR
on:
workflow_dispatch:
inputs:
version:
description: 'Version tag for this JAR (e.g., 1.0.0, beta-1)'
required: true
type: string
jobs:
create-upload-release:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Create draft release for JAR upload
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: jar-${{ inputs.version }}
release_name: Server JAR - ${{ inputs.version }}
body: |
## Upload Instructions
1. Edit this release
2. Upload the `HytaleServer.jar` file as a release asset
3. Publish the release (or keep as draft)
4. Run the "Extract Hytale Packets" workflow with:
- Version: `${{ inputs.version }}`
- JAR URL: Use the direct download URL of the uploaded JAR
### Getting the JAR URL
After uploading, the URL format will be:
```
https://github.com/${{ github.repository }}/releases/download/jar-${{ inputs.version }}/HytaleServer.jar
```
draft: true
prerelease: true
- name: Output instructions
run: |
echo "## Next Steps" >> $GITHUB_STEP_SUMMARY
echo "" >> $GITHUB_STEP_SUMMARY
echo "1. Go to the [draft release](${{ steps.create_release.outputs.html_url }})" >> $GITHUB_STEP_SUMMARY
echo "2. Upload your \`HytaleServer.jar\` file" >> $GITHUB_STEP_SUMMARY
echo "3. Publish the release" >> $GITHUB_STEP_SUMMARY
echo "4. Run the **Extract Hytale Packets** workflow with:" >> $GITHUB_STEP_SUMMARY
echo " - Version: \`${{ inputs.version }}\`" >> $GITHUB_STEP_SUMMARY
echo " - JAR URL: \`https://github.com/${{ github.repository }}/releases/download/jar-${{ inputs.version }}/HytaleServer.jar\`" >> $GITHUB_STEP_SUMMARY