Skip to main content

ralph/commands/init/
mod.rs

1//! Initialization command facade.
2//!
3//! Purpose:
4//! - Expose the Ralph initialization workflow from a thin command module.
5//!
6//! Responsibilities:
7//! - Re-export initialization options, result types, and README helpers.
8//! - Keep workflow orchestration, migration checks, and tests in focused companions.
9//!
10//! Scope:
11//! - This module coordinates `ralph init` implementation only.
12//! - CLI parsing remains in `crate::cli::init`.
13//!
14//! Usage:
15//! - Called by CLI handlers, tutorial flows, and integration tests.
16//!
17//! Invariants/assumptions:
18//! - Interactive and non-interactive initialization share the same underlying workflow.
19//! - README and writer helpers remain delegated to dedicated submodules.
20
21pub mod gitignore;
22pub mod readme;
23pub mod wizard;
24pub mod writers;
25
26mod migration_check;
27#[cfg(test)]
28mod tests;
29mod types;
30mod workflow;
31
32pub use crate::constants::versions::README_VERSION;
33pub use readme::{
34    ReadmeCheckResult, ReadmeVersionError, check_readme_current, check_readme_current_from_root,
35    extract_readme_version,
36};
37pub use types::{FileInitStatus, InitOptions, InitReport};
38pub use wizard::{WizardAnswers, print_completion_message, run_wizard};
39pub use workflow::run_init;
40pub use writers::{write_config, write_done, write_queue};