-
-
Notifications
You must be signed in to change notification settings - Fork 178
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds a dump registry command #786
Adds a dump registry command #786
Conversation
Last commit published: 3fa69007fb68dff0a2520ee6bf943d802af94b12. PR PublishingThe artifacts published by this PR:
Repository DeclarationIn order to use the artifacts published by the PR, add the following repository to your buildscript: repositories {
maven {
name 'Maven for PR #786' // https://github.com/neoforged/NeoForge/pull/786
url 'https://prmaven.neoforged.net/NeoForge/pr786'
content {
includeModule('net.neoforged', 'testframework')
includeModule('net.neoforged', 'neoforge')
}
}
} MDK installationIn order to setup a MDK using the latest PR version, run the following commands in a terminal. mkdir NeoForge-pr786
cd NeoForge-pr786
curl -L https://prmaven.neoforged.net/NeoForge/pr786/net/neoforged/neoforge/20.4.250-pr-786-RegistryDumpCommand/mdk-pr786.zip -o mdk.zip
jar xf mdk.zip
rm mdk.zip || del mdk.zip To test a production environment, you can download the installer from here. |
I would suggest sending the output files to folders by namespace, transforming |
Command is now |
src/main/java/net/neoforged/neoforge/server/command/CommandUtils.java
Outdated
Show resolved
Hide resolved
src/main/java/net/neoforged/neoforge/server/command/DumpCommand.java
Outdated
Show resolved
Hide resolved
src/main/java/net/neoforged/neoforge/server/command/DumpCommand.java
Outdated
Show resolved
Hide resolved
src/main/java/net/neoforged/neoforge/server/command/DumpCommand.java
Outdated
Show resolved
Hide resolved
…unt/NeoForge into RegistryDumpCommand
This adds a very useful command that can dump the entries of any registry into a file.
Edit: see later comments for command change/neoforge registryDump <registry> <alphabeticalSort> <printNumericIds>
The command has ability to autocomplete a registry name and display what is selectable. Works with worldgen registries as well. The options available are if to sort entries alphabetically or print numeric ids. If numeric id is true and alphabetical is false, the file will be sorted by the numeric id automatically.
The output of the command says what registry it was using and adds a clickable link that will open the file automatically for you.
Location of the file is put into the
registry_dumps
folder in the game directory (next to the configs and mods folder)Images of how command looks and file outputs:
Errors thrown during file write would appear like this:
Closes #782