Files
confique/Cargo.toml
Lukas Kalbertodt 49828fc2e3 Change API of parse_env functions
I think this is an overall improvement. A few things done here:
- They are available as `::env::parse` instead of `::env_utils`. The
  `env` module gets functions of its own soon enough.
- Renamed functions to be shorter: `list_by_sep`, `list_by_comma`, ...
- The docs were adjusted. One example is enough. And the functions with
  a fixed separator don't need the full docs again. That way we can
  avoid the `paste` dependency.
- Functions now always return `Result<C, _>`. While the previous version
  was slightly more flexible, I don't think anyone would benefit from
  that flexibility (as `parse_env` requires `Result<_, _>` anyway) and
  this way it's a bit clearer what the function does, especially for
  those who don't know the nifty `FromIterator for Result` impl.
- The example was adjusted accordingly. I also changed the names to
  obviously dummy names as I didn't know the existing names and don't
  want to spend time investigating whether I want their names in my
  code base :D
2022-11-06 12:26:36 +01:00

37 lines
919 B
TOML

[package]
name = "confique"
version = "0.2.0"
authors = ["Lukas Kalbertodt <lukas.kalbertodt@gmail.com>"]
edition = "2021"
description = "Type-safe, layered, light-weight, `serde`-based configuration library"
documentation = "https://docs.rs/confique/"
repository = "https://github.com/LukasKalbertodt/confique/"
readme = "README.md"
license = "MIT/Apache-2.0"
keywords = ["config", "configuration", "conf", "serde", "type-safe"]
categories = ["config"]
exclude = [".github"]
[[example]]
name = "simple"
required-features = ["toml"]
[features]
default = ["toml", "yaml", "json5"]
yaml = ["serde_yaml"]
[dependencies]
confique-macro = { version = "=0.0.5", path = "macro" }
json5 = { version = "0.4.1", optional = true }
serde = { version = "1", features = ["derive"] }
serde_yaml = { version = "0.8", optional = true }
toml = { version = "0.5", optional = true }
[dev-dependencies]
pretty_assertions = "1.2.1"