Please sign in to access this page

makemcserver CLI Tool

makemcserver CLI Tool

6 devlogs
5h 36m
Created by Sam V

A command line tool to help you easily set up a Minecraft server, useful if you need to quickly set up a server to run on your local PC without having to go into a web browser and manually download lots of files. The tool has the option to choose the specific Minecraft version you want as well as install mods.

Timeline

Ship 1

Sam V

21 days ago

Sam V Covers 6 devlogs and 5h 36m
Sam V
Sam V
1h 16m 21 days ago

The tool now loads the config file from different locations such as in the .config folder on Linux, and a default config is used if no config can be found. Additionally, it can download the vanilla server jar file if there is no Fabric version available. I also added a few other finishing touches and polishes including writing a README file to prepare to publish the project to NPM so that anyone can use it.

Update attachment
Sam V
Sam V
1h 42m 21 days ago

Added support for a config file that lets the user customise the mod presets as well as specifying Java paths for different versions. Additionally, the console logs now show the name of a mod instead of just the ID, so the user actually knows what's being installed.

Update attachment

The tool now writes the server.properties, eula.txt, and start.sh script (Mac/Linux) or start.cmd (Windows) files to disk.

Update attachment

Added a function to download the fabric loader (the server .jar file). It retrieves the latest version of the file from fabricmc.net using its API. I also created some useful helper functions such as fetchJson() and downloadFile() to avoid repeating large chunks of code, and the program now creates directories that don't yet exist but are required.

Update attachment

Added integration with the Modrinth API to support downloading mods. There is currently a pre-defined list of mods that will be downloaded for convenience, which are identified by their Modrinth IDs so that they should be permanently correct. The code downloads the latest release version of the mod for the specified version (or a beta or alpha version if there is no release version) and shows a failure message if the mod is unavailable for the chosen version.

Update attachment

I set up the nodejs project and added the basic questions using the prompts library. The list of possible game versions is retrieved from official Mojang servers so it won't go out of date.

Update attachment