[package]
name = "utcnow"
version = "0.2.7"
edition = "2018"
readme = "README.md"
categories = ["date-and-time", "no-std"]
keywords = ["time", "unixtime", "utc", "no_std", "cross-platform"]
authors = ["René Kijewski <crates.io@k6i.de>"]
repository = "https://github.com/Kijewski/utcnow"
description = "Get the current unixtime in a no-std context"
license = "Apache-2.0"
[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--generate-link-to-definition", "--cfg=docsrs"]
[dependencies]
const_fn = "0.4.9"
rustversion = "1.0.0"
arbitrary = { version = "1", default-features = false, optional = true }
castaway = { version = "0.2", default-features = false, optional = true }
proptest = { version = "1", default-features = false, optional = true, features = ["std"] }
quickcheck = { version = "1", default-features = false, optional = true }
rkyv = { version = "0.7.27", optional = true }
serde = { version = "1", default-features = false, optional = true }
[dev-dependencies]
quickcheck_macros = { version = "1", default-features = false }
rand = { version = "0.8.3", default-features = false }
serde_json = { version = "1.0.47", default-features = false, features = ["alloc"] }
[target.'cfg(any(target_os = "dragonfly", target_os = "freebsd", target_os = "ios", target_os = "linux", target_os = "macos", target_os = "openbsd", target_os = "redox"))'.dependencies]
rustix = { version = ">= 0.37, < 0.39", features = ["time"] }
[target.'cfg(any(target_os = "android", target_os = "emscripten", target_os = "fuchsia", target_os = "haiku", target_os = "illumos", target_os = "netbsd", target_os = "solaris"))'.dependencies]
errno = { version = "0.3.0", default-features = false }
libc = { version = "0.2.126", default-features = false }
[target.'cfg(target_os = "windows")'.dependencies]
winapi = { version = "0.3.9", default-features = false, features = ["sysinfoapi"] }
[target.'cfg(target_os = "wasi")'.dependencies]
wasi = { version = "0.11.0", default-features = false }
[target.'cfg(all(target_arch = "wasm32", not(target_os = "wasi")))'.dependencies]
js-sys = "0.3.0"
wasm-bindgen = "0.2.0"
[target.'cfg(all(target_arch = "wasm32", not(target_os = "wasi")))'.dev-dependencies]
wasm-bindgen-test = "0.3.13"
[features]
default = ["std", "fallback"]
fallback = []
std = []
[lints.rust]
absolute_paths_not_starting_with_crate = "warn"
elided_lifetimes_in_paths = "warn"
explicit_outlives_requirements = "warn"
meta_variable_misuse = "warn"
missing_copy_implementations = "warn"
missing_debug_implementations = "warn"
missing_docs = "warn"
non_ascii_idents = "warn"
noop_method_call = "warn"
single_use_lifetimes = "warn"
trivial_casts = "warn"
unreachable_pub = "warn"
unused_lifetimes = "warn"
unused_results = "warn"
warnings = "warn"
[lints.clippy]
collapsible_match = "warn"
expect_used = "warn"
match_bool = "warn"
match_ref_pats = "warn"
match_same_arms = "warn"
match_single_binding = "warn"
needless_bool = "deny"
needless_late_init = "warn"
needless_match = "warn"
redundant_guards = "warn"
redundant_pattern = "warn"
redundant_pattern_matching = "warn"
single_match = "warn"
single_match_else = "warn"
[profile.dev]
panic = "abort"
[profile.release]
panic = "abort"