tutorial:minotaur
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
tutorial:minotaur [2021/03/17 18:39] – Rename Advanced to Absurd haykam | tutorial:minotaur [2022/04/25 20:15] – external edit 127.0.0.1 | ||
---|---|---|---|
Line 2: | Line 2: | ||
Minotaur is a Gradle plugin similar to CurseGradle. | Minotaur is a Gradle plugin similar to CurseGradle. | ||
- | This page only goes through the basics of Minotaur, you should [[https:// | + | This page only goes through the basics of Minotaur, |
===== Basic ===== | ===== Basic ===== | ||
- | First of all, add the minotaur | + | First of all, add the Minotaur |
<code groovy> | <code groovy> | ||
plugins { | plugins { | ||
- | id " | + | id " |
} | } | ||
</ | </ | ||
- | Now you can create | + | Minotaur registers |
Here is a basic example. | Here is a basic example. | ||
<code groovy> | <code groovy> | ||
- | import com.modrinth.minotaur.TaskModrinthUpload | + | import com.modrinth.minotaur.dependencies.ModDependency |
- | task publishModrinth (type: TaskModrinthUpload) | + | modrinth |
- | token = ' | + | token = ' |
- | projectId = 'modrinthModID' // The ID of your modrinth | + | projectId = 'AABBCCDD' // The ID of your Modrinth |
- | versionNumber = ' | + | versionNumber = ' |
- | uploadFile = remapJar // This links to a task that builds your mod jar and sets " | + | versionName = 'My awesome release' |
- | | + | uploadFile = remapJar // Tells Minotaur |
- | | + | |
+ | loaders = [' | ||
+ | | ||
+ | new ModDependency('P7dR8mSH', | ||
+ | ] | ||
} | } | ||
</ | </ | ||
- | Get your Modrinth [[https:// | + | Get your Modrinth [[https:// |
- | Now when you run '' | + | Now, when you run '' |
{{https:// | {{https:// | ||
- | However, this can be limiting and sometimes repetitive to upload, you would need to edit the values every time you want to release a version. | + | However, this can be limiting and sometimes repetitive to upload, |
This is where Java '' | This is where Java '' | ||
Line 53: | Line 57: | ||
Now you can collect user input by simply calling the method: '' | Now you can collect user input by simply calling the method: '' | ||
- | Let's add this to our task, shall we? We'll also add some more data, such as a markdown | + | Let's add this to our task, shall we? We'll also add some more data, such as a Markdown |
<code groovy> | <code groovy> | ||
- | import com.modrinth.minotaur.TaskModrinthUpload | + | modrinth { |
- | + | ||
- | task publishModrinth (type: TaskModrinthUpload) | + | |
BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); | BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); | ||
- | System.out.println(" | + | System.out.println(" |
- | token = br.readLine(); | + | token = br.readLine(); |
- | projectId = "" | + | projectId = "" |
System.out.println(" | System.out.println(" | ||
versionNumber = br.readLine(); | versionNumber = br.readLine(); | ||
System.out.println(" | System.out.println(" | ||
versionName = br.readLine(); | versionName = br.readLine(); | ||
- | uploadFile = remapJar | + | uploadFile = remapJar |
System.out.println(" | System.out.println(" | ||
- | | + | |
System.out.println(" | System.out.println(" | ||
changelog = br.readLine(); | changelog = br.readLine(); | ||
- | | + | |
} | } | ||
</ | </ | ||
- | Now, when '' | + | Now, when '' |
- | Minotaur is great alongside CurseGradle. You can merge both of the tasks together. | + | Minotaur is great alongside CurseGradle. You can merge both of the tasks together. |
<code groovy> | <code groovy> | ||
- | task publishModrinth (type: TaskModrinthUpload) | + | task publishToModSites |
- | | + | |
- | curseforge<id> // Begin the cursegradle task. Replacing ID with the id you set on the cursegradle config. | + | |
} | } | ||
</ | </ | ||
+ | ===== Updating from Minotaur 1.x to 2.x ===== | ||
+ | |||
+ | Minotaur 2.x introduced a few breaking changes to how your buildscript is formatted. | ||
+ | |||
+ | First, instead of registering your own '' | ||
+ | To declare supported Minecraft versions and mod loaders, the '' | ||
+ | Instead of using '' | ||
+ | Finally, dependencies are also an array which take '' |
tutorial/minotaur.txt · Last modified: 2022/10/22 23:48 by budavissza