# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
name = "r-token"
version = "0.1.4"
authors = ["Kayano <Kayano04@outlook.jp>"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "A simple and efficient token generation library for Rust, ideal for API authentication and session management."
readme = "README.md"
keywords = [
    "token",
    "uuid",
    "api",
    "web",
]
categories = [
    "api-bindings",
    "development-tools",
    "network-programming",
]
license = "MIT"
repository = "https://github.com/KayanoLiam/r-token.git"

[features]
actix = ["dep:actix-web"]
default = ["actix"]
redis = [
    "dep:redis",
    "dep:tokio",
]
redis-actix = [
    "redis",
    "actix",
]

[lib]
name = "r_token"
path = "src/lib.rs"

[[bin]]
name = "r-token"
path = "src/main.rs"
required-features = ["actix"]

[[bin]]
name = "r-token-redis"
path = "src/bin/redis_main.rs"
required-features = ["redis-actix"]

[[test]]
name = "error_tests"
path = "tests/error_tests.rs"

[[test]]
name = "integration_tests"
path = "tests/integration_tests.rs"

[[test]]
name = "performance_tests"
path = "tests/performance_tests.rs"

[[test]]
name = "redis_tests"
path = "tests/redis_tests.rs"

[dependencies.actix-web]
version = "4"
optional = true

[dependencies.chrono]
version = "0.4.42"

[dependencies.redis]
version = "1.0.2"
features = [
    "tokio-comp",
    "connection-manager",
]
optional = true

[dependencies.serde]
version = "1.0"
features = ["derive"]

[dependencies.tokio]
version = "1"
features = ["sync"]
optional = true

[dependencies.uuid]
version = "1.0"
features = ["v4"]

[dev-dependencies.tokio]
version = "1"
features = [
    "macros",
    "rt-multi-thread",
    "time",
]
