mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-09 03:57:24 +00:00
07041ace37
cros_async and by extension serde_keyvalue are needed on ChromeOS, so add the `# provided by ebuild` comments where appropriate to make it possible to uprev cros_async (which requires pulling in serde_keyvalue). BUG=b:250883877 TEST=kokoro passes Change-Id: I423cac0c4e5e30afac058b914358caca7d27edbf Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/3953082 Auto-Submit: Allen Webb <allenwebb@google.com> Commit-Queue: Dennis Kempin <denniskempin@google.com> Reviewed-by: Dennis Kempin <denniskempin@google.com> |
||
---|---|---|
.. | ||
serde_keyvalue_derive | ||
src | ||
Cargo.toml | ||
README.md |
Serde deserializer from key=value strings
A lightweight serde deserializer for strings containing key-value pairs separated by commas, as commonly found in command-line parameters.
Say your program takes a command-line option of the form:
--foo type=bar,active,nb_threads=8
This crate provides a from_key_values
function that deserializes these key-values into a
configuration structure. Since it uses serde, the same configuration structure can also be created
from any other supported source (such as a TOML or YAML configuration file) that uses the same keys.
Integration with the argh command-line parser is also provided via
the argh_derive
feature.
See the inline documentation for examples and more details.