-
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch '1.21.3-neoforge' into 1.21-neoforge
- Loading branch information
Showing
12 changed files
with
809 additions
and
135 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# To get started with Dependabot version updates, you'll need to specify which | ||
# package ecosystems to update and where the package manifests are located. | ||
# Please see the documentation for all configuration options: | ||
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file | ||
|
||
version: 2 | ||
updates: | ||
- package-ecosystem: "gradle" | ||
directory: "/" | ||
schedule: | ||
interval: "daily" | ||
|
||
- package-ecosystem: "github-actions" | ||
# Directory should be `/` instead of `/.github/workflows` according to the docs. | ||
directory: "/" | ||
schedule: | ||
interval: "daily" |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,9 @@ | ||
name: Publish Release | ||
run-name: "Publish release from ${{ github.ref_name }} branch" | ||
|
||
permissions: | ||
# Needed to push the tag. | ||
contents: write | ||
|
||
on: | ||
workflow_dispatch: | ||
|
@@ -28,6 +33,11 @@ on: | |
required: true | ||
type: boolean | ||
default: true | ||
update_website: | ||
description: "Update wimods.net post (only works if there already is one and publish_curseforge is true)" | ||
required: false | ||
type: boolean | ||
default: false | ||
|
||
jobs: | ||
publish: | ||
|
@@ -37,9 +47,13 @@ jobs: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
CURSEFORGE_API_KEY: ${{ secrets.CURSEFORGE_API_KEY }} | ||
MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }} | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
with: | ||
# Include all tags in case the new tag already exists. | ||
fetch-tags: true | ||
|
||
- name: Set up Java 21 | ||
uses: actions/setup-java@v4 | ||
|
@@ -58,11 +72,11 @@ jobs: | |
|
||
- name: Create and push tag | ||
run: | | ||
MOD_VERSION=$(grep "mod_version" gradle.properties | cut -d'=' -f2 | tr -d ' ') | ||
MOD_VERSION=$(grep "mod_version" gradle.properties | cut -d'=' -f2 | tr -d ' \r') | ||
git config --global user.name "Wurst-Bot" | ||
git config --global user.email "[email protected]" | ||
git tag v$MOD_VERSION | ||
git push origin v$MOD_VERSION | ||
git tag "v$MOD_VERSION" | ||
git push origin "v$MOD_VERSION" | ||
- name: Close milestone | ||
if: ${{ inputs.close_milestone }} | ||
|
@@ -82,6 +96,29 @@ jobs: | |
if: ${{ inputs.publish_curseforge }} | ||
run: ./gradlew publishCurseforge --stacktrace | ||
|
||
- name: Get CurseForge file ID | ||
id: cf_file_id | ||
if: ${{ inputs.publish_curseforge }} | ||
run: | | ||
file_id=$(./gradlew getCurseforgeId | grep -o 'CURSEFORGE_FILE_ID=[0-9]*' | grep -o '[0-9]*') | ||
echo "file_id=$file_id" >> "$GITHUB_OUTPUT" | ||
echo "CurseForge file ID: `$file_id`" >> $GITHUB_STEP_SUMMARY | ||
- name: Publish to Modrinth | ||
if: ${{ inputs.publish_modrinth }} | ||
run: ./gradlew publishModrinth --stacktrace | ||
|
||
- name: Trigger website update | ||
if: ${{ inputs.update_website && inputs.publish_curseforge }} | ||
env: | ||
GH_TOKEN: ${{ secrets.WIMODS_NET_PUBLISH_TOKEN }} | ||
run: | | ||
MOD_VERSION=$(grep "mod_version" gradle.properties | cut -d'=' -f2 | tr -d ' \r' | sed 's/-MC.*$//') | ||
MC_VERSION=$(grep "minecraft_version" gradle.properties | cut -d'=' -f2 | tr -d ' \r') | ||
gh workflow run add_mod_port.yml \ | ||
-R Wurst-Imperium/wimods.net \ | ||
-f mod="mo-glass" \ | ||
-f modloader="neoforge" \ | ||
-f mod_version="$MOD_VERSION" \ | ||
-f mc_version="$MC_VERSION" \ | ||
-f file_id="${{ steps.cf_file_id.outputs.file_id }}" |
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
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
Oops, something went wrong.