Skip to content

Commit

Permalink
Backport to Minecraft 1.19.4 (#20)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hantonik committed Jun 17, 2024
1 parent 0f3bce4 commit 2ef53e0
Show file tree
Hide file tree
Showing 152 changed files with 6,558 additions and 8,795 deletions.
26 changes: 9 additions & 17 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
name: 'Bug report'
description: 'If you notice any bugs or problems with FBP, report them here!'

title: '[Bug] <title>'
title: '[Bug] '
labels: [ 'bug' ]
assignees: [ 'Hantonik' ]

body:
- type: markdown
Expand All @@ -17,7 +16,7 @@ body:
label: 'Issue description:'
description: |
"It doesn't work" is not really helpful.
placeholder: 'Description'
placeholder: 'Description...'
validations:
required: true
- type: textarea
Expand All @@ -35,7 +34,7 @@ body:
- type: input
attributes:
label: 'FBP version:'
placeholder: '1.0.0.0'
placeholder: 'e.g. 1.0.0.0'
validations:
required: true
- type: dropdown
Expand All @@ -44,30 +43,23 @@ body:
description: |
Older versions are **not** supported!
options:
- '1.20.6'
- '1.20.4'
- '1.20.1'
- '1.19.4'
- '1.19.2'
- '1.18.2'
- '1.17.1'
- '1.16.5'
multiple: true
validations:
required: true
- type: dropdown
attributes:
label: 'Modloader:'
description: |
What modloader does the bug occur on?
multiple: true
options:
- 'Forge'
- 'NeoForge'
- 'Fabric'
validations:
required: true
- type: input
attributes:
label: 'Modloader version:'
placeholder: 'Forge / NeoForge / Fabric'
description: |
What modloader does the bug occur on?
placeholder: 'e.g. Forge 47.2.0'
validations:
required: true
- type: textarea
Expand Down
27 changes: 15 additions & 12 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
name: 'Feature request'
description: 'Have any suggestions? Let me know about them here!'

title: '[Feature] <title>'
title: '[Feature] '
labels: [ 'enhancement' ]
assignees: [ 'Hantonik' ]

body:
- type: markdown
Expand All @@ -16,32 +15,36 @@ body:
label: 'Feature description:'
description: |
Please describe your idea as clearly as you can.
placeholder: 'Description, context, etc...'
placeholder: 'Description...'
validations:
required: true
- type: dropdown
attributes:
label: 'Minecraft version:'
description: |
What version of Minecraft would you like this on?
You can skip this if your request is not tied to any version.
Older versions are **not** supported!
**You can skip this if your request is not tied to any version.**
multiple: true
options:
- '1.16.5'
- '1.17.1'
- '1.18.2'
- '1.19.4'
- '1.20.4'
- '1.21'
- 'Newer'
- '1.21'
- '1.20.6'
- '1.20.4'
- '1.20.1'
- '1.19.4'
- '1.19.2'
- '1.18.2'
- '1.17.1'
- '1.16.5'
- type: dropdown
attributes:
label: 'Modloader:'
description: |
What modloader would you like this on?
You can skip this if your request is not tied to any modloader (or select both).
**You can skip this if your request is not tied to any modloader.**
multiple: true
options:
- 'Forge'
Expand Down
25 changes: 10 additions & 15 deletions .github/workflows/build-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,17 @@ on:

push:
branches:
- 'feature/**'
- 'dev/**'
- '*/**'

workflow_dispatch:

jobs:
build:
name: 'Build PR'
runs-on: ubuntu-latest
strategy:
matrix:
loader: [ 'Forge', 'Fabric' ]

steps:
- name: 'Checkout repository'
Expand All @@ -33,22 +35,15 @@ jobs:
java-version: '17'
distribution: 'temurin'

- name: 'Build with Gradle'
- name: 'Build ${{ matrix.loader }} with Gradle'
uses: gradle/gradle-build-action@v2
with:
arguments: build
arguments: :${{ matrix.loader }}:build
cache-read-only: false

- name: 'Move artifacts'
shell: bash
run: |
mkdir artifacts
cp Fabric/build/libs/*.jar artifacts
cp Forge/build/libs/*.jar artifacts
- name: 'Upload artifacts'
uses: actions/upload-artifact@v3
- name: 'Upload ${{ matrix.loader }} artifacts'
uses: actions/upload-artifact@v4
with:
if-no-files-found: error
name: 'Artifacts'
path: artifacts/*
name: 'Artifacts-${{ matrix.loader }}'
path: ${{ matrix.loader }}/build/libs/*.jar
22 changes: 9 additions & 13 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ jobs:
build:
name: 'Build'
runs-on: ubuntu-latest
strategy:
matrix:
loader: [ 'Forge', 'Fabric' ]

steps:
- name: 'Checkout repository'
Expand All @@ -28,22 +31,15 @@ jobs:
java-version: '17'
distribution: 'temurin'

- name: 'Build with Gradle'
- name: 'Build ${{ matrix.loader }} with Gradle'
uses: gradle/gradle-build-action@v2
with:
arguments: build
arguments: :${{ matrix.loader }}:build
cache-read-only: false

- name: 'Move artifacts'
shell: bash
run: |
mkdir artifacts
cp Fabric/build/libs/*.jar artifacts
cp Forge/build/libs/*.jar artifacts
- name: 'Upload artifacts'
uses: actions/upload-artifact@v3
- name: 'Upload ${{ matrix.loader }} artifacts'
uses: actions/upload-artifact@v4
with:
if-no-files-found: error
name: 'Artifacts'
path: artifacts/*
name: 'Artifacts-${{ matrix.loader }}'
path: ${{ matrix.loader }}/build/libs/*.jar
59 changes: 31 additions & 28 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,14 @@ name: 'Publish'
on:
workflow_dispatch:
inputs:
suffix:
type: string
required: false
label:
type: choice
description: 'Version label'
options:
- -beta
- -alpha
default: ''
description: 'Suffix/Release type'
required: false

permissions:
contents: write
Expand All @@ -17,6 +20,9 @@ jobs:
build:
name: 'Build'
runs-on: ubuntu-latest
strategy:
matrix:
loader: [ 'Forge', 'Fabric' ]

steps:
- name: 'Checkout repository'
Expand All @@ -31,25 +37,18 @@ jobs:
java-version: '17'
distribution: 'temurin'

- name: 'Build with Gradle'
- name: 'Build ${{ matrix.loader }} with Gradle'
uses: gradle/gradle-build-action@v2
with:
arguments: build
arguments: :${{ matrix.loader }}:build
cache-read-only: false

- name: 'Move artifacts'
shell: bash
run: |
mkdir artifacts
cp Fabric/build/libs/*.jar artifacts
cp Forge/build/libs/*.jar artifacts
- name: 'Upload artifacts'
uses: actions/upload-artifact@v3
- name: 'Upload ${{ matrix.loader }} artifacts'
uses: actions/upload-artifact@v4
with:
if-no-files-found: error
name: 'Artifacts'
path: artifacts/*
name: 'Artifacts-${{ matrix.loader }}'
path: ${{ matrix.loader }}/build/libs/*.jar

changelog:
name: 'Generate changelog'
Expand All @@ -75,7 +74,7 @@ jobs:
cache-read-only: false

- name: 'Upload changelog'
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
if-no-files-found: error
name: 'Changelog'
Expand Down Expand Up @@ -103,7 +102,7 @@ jobs:
distribution: 'temurin'

- name: 'Download changelog'
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: 'Changelog'
path: Changelog/
Expand Down Expand Up @@ -139,7 +138,7 @@ jobs:
fallback: '0.0.0.0'

- name: 'Download changelog'
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: 'Changelog'
path: Changelog/
Expand All @@ -149,27 +148,31 @@ jobs:
with:
include: Changelog/**
find: "${version}"
replace: "`${{ steps.latest-tag.outputs.tag }}${{ inputs.suffix }}`"
replace: "`${{ steps.latest-tag.outputs.tag }}${{ inputs.label }}`"
regex: false

- name: 'Download artifacts'
uses: actions/download-artifact@v3
- name: 'Download ${{ matrix.loader }} artifacts'
uses: actions/download-artifact@v4
with:
name: 'Artifacts'
pattern: 'Artifacts-*'
path: artifacts/
merge-multiple: true

- name: 'Create release'
uses: softprops/action-gh-release@v1
with:
name: "${{ github.event.repository.name }}-${{ github.ref_name }}-${{ steps.latest-tag.outputs.tag }}${{ inputs.suffix }}"
name: "${{ github.event.repository.name }}-${{ github.ref_name }}-${{ steps.latest-tag.outputs.tag }}${{ inputs.label }}"
tag_name: ${{ steps.latest-tag.outputs.tag }}
target_commitish: ${{ github.ref }}
body_path: Changelog/changelog.md
files: artifacts/*
files: |
'artifacts/*'
'!artifacts/*-slim.*'
- name: 'Upload changelog'
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
if-no-files-found: error
name: Changelog
path: Changelog/changelog.**
path: Changelog/changelog.**
overwrite: true
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,11 @@ replay_*.log
/setup.bat
/.idea/
/.gradle/
/Common/src/test/
/Forge/src/test/
/NeoForge/src/test/
/Fabric/src/test/
/Common/run/
/Forge/run/
/NeoForge/run/
/Fabric/run/
Expand Down
12 changes: 11 additions & 1 deletion Changelog/templates/changelog-html.mustache
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
<p><span style="font-size: 18px;"><strong>Release ${version}:</strong></span></p>
<ul>
{{#commits}}
<li>{{messageTitle}}</li>
<li>
{{messageTitle}}

<ul>
{{#messageBodyItems}}
<li>
{{.}}
</li>
{{/messageBodyItems}}
</ul>
</li>
{{/commits}}
</ul>
3 changes: 3 additions & 0 deletions Changelog/templates/changelog-markdown.mustache
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Release ${version}:
{{#commits}}
- {{messageTitle}}
{{#messageBodyItems}}
* {{.}}
{{/messageBodyItems}}
{{/commits}}
Loading

0 comments on commit 2ef53e0

Please sign in to comment.