diff options
| author | A Farzat <a@farzat.xyz> | 2026-06-21 11:36:08 +0300 |
|---|---|---|
| committer | A Farzat <a@farzat.xyz> | 2026-06-21 11:36:08 +0300 |
| commit | 1bfa644e012de8c26551d33b7d672f99031f8c41 (patch) | |
| tree | 51c2d5e03c3809518e00328ecfe59efba6a024fd | |
| parent | ea5c36fff4922c06181e1942d7db36ebb96cfd1b (diff) | |
| download | repo2markdown-1bfa644e012de8c26551d33b7d672f99031f8c41.tar.gz repo2markdown-1bfa644e012de8c26551d33b7d672f99031f8c41.zip | |
Add module/function docs to run.rs
| -rw-r--r-- | src/run.rs | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -1,3 +1,9 @@ +//! Runtime orchestration for the `repo2markdown` binary. +//! +//! This module connects parsed CLI options with stdin path-list parsing and Markdown generation. +//! It reads a NUL-separated list of paths from input, then renders either plain Markdown or a +//! fenced Markdown document depending on the CLI configuration. + use std::io::{Read, Write}; use repo2markdown::{ @@ -7,6 +13,13 @@ use repo2markdown::{ use crate::cli::Cli; +/// Runs the main `repo2markdown` pipeline. +/// +/// The input stream is read as a NUL-separated path list. Empty path segments are ignored by the +/// path-list parser. Paths are resolved and rendered according to `cli` options. +/// +/// When `cli.fenced` is set, the full generated Markdown document is wrapped in an outer Markdown +/// fence. Otherwise, plain Markdown is written directly to `output`. pub fn run<R: Read, W: Write>( cli: &Cli, mut input: R, |
