utils

utils just contains a few functions for helping you.

get_minecraft_directory() -> str

Returns the path to the standard minecraft directory.

get_latest_version() -> Dict[str,str]

Returns the latest versions of snapshot and release.

get_version_list() -> List[Dict[str,str]]

Returns a list of all versions with the type.

get_installed_versions(minecraft_directory: Union[str, os.PathLike])  -> List[Dict[str,str]]

Returns a list with all installed versions in the given path.

get_available_versions(minecraft_directory: Union[str, os.PathLike]) -> List[Dict[str,str]]

Returns a list with all installable and only local installed (e.g. Forge) versions.

get_java_executable() -> str

Return the path to the java executable. This may not work correctly on all systems.

get_library_version() -> str

Return the version of the library.

generate_test_options() -> Dict[str,str]

Generates test options for get_minecraft_command(). Use this function to test launching without logging in. This should not be used in production.

is_version_valid(version: str,minecraft_directory: Union[str, os.PathLike]) -> bool

Checks if the given version exists

get_minecraft_news(page_size: int = 20) -> Dict

Get the news from minecraft.net

is_vanilla_version(version: str) -> bool

Checks if the given version is a vanilla version