use crate::config::{ConfigEnvironment, RealConfigEnvironment};
use crate::logger::Colors;
use crate::templates::{get_template, list_templates, ALL_TEMPLATES};
use itertools::Itertools;
use std::path::Path;
trait StdIoWriteCompat {
fn write_fmt(&mut self, args: std::fmt::Arguments<'_>) -> std::io::Result<()>;
}
impl<T: std::io::Write> StdIoWriteCompat for T {
fn write_fmt(&mut self, args: std::fmt::Arguments<'_>) -> std::io::Result<()> {
std::io::Write::write_fmt(self, args)
}
}
const MIN_SIMILARITY_PERCENT: u32 = 40;
include!("init/project_detection.rs");
mod config_generation;
pub use config_generation::{
handle_check_config, handle_check_config_with, handle_init_global, handle_init_global_with,
handle_init_local_config, handle_init_local_config_with, handle_init_state_inference_with_env,
handle_init_template_arg_at_path_with_env,
};
include!("init/prompting.rs");
include!("init/work_guides.rs");
include!("init/smart_init.rs");
include!("init/extended_help.rs");
#[cfg(test)]
mod tests {
include!("init/tests.rs");
}