cli

package
v1.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 15, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AcceptEula

func AcceptEula()

AcceptEula updates the eula.txt file to set 'eula=true' if 'eula=false' is found.

No parameters. No return values.

func HelloShow

func HelloShow(version string)

HelloShow prints the Minecraft-Server-AutoCreation version to the console in red color.

Parameters: - version: the version of the Minecraft-Server-AutoCreation application.

Return type: None.

func PrepareStart

func PrepareStart(versionSpigot string, versionApp string)

PrepareStart prepares the start.bat file for Minecraft server with the given Spigot version and application version.

Parameters: - versionSpigot: the version of Spigot for the Minecraft server. - versionApp: the version of the Minecraft-Server-AutoCreation application.

func Spigot

func Spigot(spigotUrl string) ([]string, error)

Spigot makes an HTTP GET request to the given spigotUrl and retrieves the list of versions from the response. It returns a slice of strings representing the versions and an error if any occurred.

Parameters: - spigotUrl: a string representing the URL to make the GET request to.

Returns: - []string: a slice of strings representing the versions retrieved from the response. - error: an error if any occurred during the HTTP request or parsing the response.

func SpigotDownload

func SpigotDownload(spigotUrlJar string) error

SpigotDownload downloads a file from the provided URL and saves it locally.

It takes the spigotUrlJar string as input and returns an error if any.

func StartBat

func StartBat(version string, versionApp string)

StartBat starts the execution of the start.bat file with the given version and versionApp.

Parameters: - version: the version of the Minecraft server to be created. - versionApp: the version of the Minecraft-Server-AutoCreation application.

No return values.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL