[package]
name = "lazymc"
version = "0.2.3"
authors = ["Tim Visee <3a4fb3964f@sinenomine.email>"]
license = "GPL-3.0"
readme = "README.md"
homepage = "https://timvisee.com/projects/lazymc"
repository = "https://gitlab.com/timvisee/lazymc"
description = "Put your Minecraft server to rest when idle."
keywords = ["minecraft", "server", "idle", "cli"]
categories = [
    "command-line-interface",
    "games",
]
exclude = [
    "/.github",
    "/contrib",
]
edition = "2021"

[features]
default = ["rcon", "lobby"]

# RCON support
# Allow use of RCON to manage (stop) server.
# Required on Windows.
rcon = ["rust_rcon", "async-std"]

# Lobby support
# Add lobby join method, keeps client in fake lobby world until server is ready.
lobby = ["named-binary-tag", "quartz_nbt", "uuid"]

[dependencies]
anyhow = "1.0"
base64 = "0.13"
bytes = "1.1"
chrono = "0.4"
clap = { version = "3.0.0-beta.5", default-features = false, features = [ "std", "cargo", "color", "env", "suggestions", "unicode" ]}
colored = "2.0"
derive_builder = "0.10"
dotenv = "0.15"
flate2 = { version = "1.0", default-features = false, features = ["default"] }
futures = { version = "0.3", default-features = false, features = ["executor"] }
log = "0.4"
minecraft-protocol = { git = "https://github.com/timvisee/rust-minecraft-protocol", rev = "356ea54" }
notify = "4.0"
pretty_env_logger = "0.4"
proxy-protocol = "0.5"
rand = "0.8"
serde = "1.0"
serde_json = "1.0"
shlex = "1.1"
thiserror = "1.0"
tokio = { version = "1", default-features = false, features = ["rt-multi-thread", "io-util", "net", "macros", "time", "process", "signal", "sync", "fs"] }
toml = "0.5"
version-compare = "0.1"

# Feature: rcon
rust_rcon = { package = "rcon", version = "0.5.2", optional = true }
async-std = { version = "1.9.0", deafult-features = false, optional = true }

# Feature: lobby
named-binary-tag = { version = "0.6", optional = true }
quartz_nbt = { version = "0.2", optional = true }
uuid = { version = "0.7", optional = true, features = ["v3"] }

[target.'cfg(unix)'.dependencies]
libc = "0.2"

[target.'cfg(windows)'.dependencies]
winapi = { version = "0.3", features = ["winuser", "processthreadsapi", "handleapi", "ntdef", "minwindef"] }
