rust_config_tree/lib.rs
1#![warn(missing_docs)]
2
3//! Configuration-tree loading and CLI helpers for layered config files.
4//!
5//! The high-level API loads `confique` schemas directly, while the lower-level
6//! tree traversal helpers remain available for custom loaders.
7//!
8//! Use [`config::ConfigSchema`] with a `confique::Config` type when your schema owns an
9//! include field. Use [`config::load_config`] to load the root config, all recursive
10//! includes, `.env` values, and schema-declared environment values into the
11//! final schema. Use [`config::build_config_figment`] or [`config::load_config_with_figment`]
12//! when you need runtime source tracking. Use [`config::write_config_templates`] or
13//! [`cli::ConfigCommand`] to generate example template files that mirror the same
14//! include tree. Use [`config::write_config_schemas`] to generate root and section JSON
15//! Schemas for editor completion and validation. Use
16//! [`cli::install_shell_completion`] and [`cli::uninstall_shell_completion`] for reusable
17//! shell completion lifecycle commands.
18
19extern crate self as rust_config_tree;
20
21pub mod cli;
22pub mod config;
23pub mod config_schema;
24pub mod error;
25pub mod path;
26pub mod template_tree;
27pub mod transparent_section;
28pub mod tree;
29
30mod cli_overrides;
31mod config_env;
32mod config_format;
33mod config_load;
34mod config_load_adapt;
35mod config_output;
36mod config_templates;
37mod config_trace;
38mod config_util;
39
40pub use rust_config_tree_macros::{ConfigOverrides, ConfigSchema};
41
42#[cfg(test)]
43#[path = "unit_tests/transparent_section.rs"]
44mod transparent_section_tests;