syncable_cli/
lib.rs

1//! # Syncable IaC CLI
2//!
3//! A Rust-based command-line application that analyzes code repositories and automatically
4//! generates Infrastructure as Code configurations including Dockerfiles, Docker Compose
5//! files, and Terraform configurations.
6//!
7//! ## Features
8//!
9//! - **Language Detection**: Automatically detects programming languages and their versions
10//! - **Framework Analysis**: Identifies frameworks and libraries used in the project
11//! - **Smart Generation**: Creates optimized IaC configurations based on project analysis
12//! - **Multiple Formats**: Supports Docker, Docker Compose, and Terraform generation
13//! - **Security-First**: Generates secure configurations following best practices
14//!
15//! ## Example
16//!
17//! ```rust,no_run
18//! use syncable_cli::{analyze_project, generate_dockerfile};
19//! use std::path::Path;
20//!
21//! # fn main() -> Result<(), Box<dyn std::error::Error>> {
22//! let project_path = Path::new("./my-project");
23//! let analysis = analyze_project(project_path)?;
24//! let dockerfile = generate_dockerfile(&analysis)?;
25//! println!("{}", dockerfile);
26//! # Ok(())
27//! # }
28//! ```
29
30pub mod analyzer;
31pub mod cli;
32pub mod common;
33pub mod config;
34pub mod error;
35pub mod generator;
36
37// Re-export commonly used types and functions
38pub use analyzer::{analyze_project, ProjectAnalysis};
39pub use error::{IaCGeneratorError, Result};
40pub use generator::{generate_dockerfile, generate_compose, generate_terraform};
41
42/// The current version of the CLI tool
43pub const VERSION: &str = env!("CARGO_PKG_VERSION");