vx_config/
lib.rs

1//! # VX Configuration Management
2//!
3//! This crate provides comprehensive configuration management for the vx tool manager.
4//! It supports layered configuration from multiple sources and automatic project detection.
5//!
6//! ## Features
7//!
8//! - **Layered Configuration**: Supports builtin defaults, user config, project config, and environment variables
9//! - **Project Detection**: Automatically detects Python, Rust, Node.js, and Go projects
10//! - **Multiple Formats**: Supports TOML, JSON, and other configuration formats
11//! - **Tool Version Management**: Manages tool versions across different project types
12//!
13//! ## Example
14//!
15//! ```rust
16//! use vx_config::ConfigManager;
17//!
18//! # async fn example() -> anyhow::Result<()> {
19//! let config_manager = ConfigManager::new().await?;
20//! let tool_version = config_manager.get_tool_version("node");
21//! # Ok(())
22//! # }
23//! ```
24
25pub mod config;
26pub mod detection;
27pub mod error;
28pub mod manager;
29pub mod parsers;
30pub mod types;
31
32// Re-export main types and functions
33pub use config::*;
34pub use error::{ConfigError, Result};
35pub use manager::ConfigManager;
36pub use types::*;
37
38/// Current version of the vx-config crate
39pub const VERSION: &str = env!("CARGO_PKG_VERSION");