From 5a23e6b3ad655b15b412720ab81b0508866bebce Mon Sep 17 00:00:00 2001 From: 魏曹先生 <1992414357@qq.com> Date: Sat, 27 Jun 2026 18:28:52 +0800 Subject: docs: improve documentation, mark internal items as `#[doc(hidden)]` Add module-level docs for the hook system, enhance doc examples for macros with usage syntax, fix typos in cross-references, and hide internal debugging macros and mock types from public documentation --- mingling_core/src/program/config.rs | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'mingling_core/src/program/config.rs') diff --git a/mingling_core/src/program/config.rs b/mingling_core/src/program/config.rs index 6d54a4e..c5f91da 100644 --- a/mingling_core/src/program/config.rs +++ b/mingling_core/src/program/config.rs @@ -42,13 +42,21 @@ pub struct ProgramStdoutSetting { pub clap_help_print_behaviour: ClapHelpPrintBehaviour, } +/// Behavior when Clap Dispatcher outputs help information #[cfg(feature = "clap")] #[derive(Debug, Default, Clone)] pub enum ClapHelpPrintBehaviour { - /// Write to RenderResult + /// Write help information to `RenderResult` instead of printing to stdout directly. + /// + /// This allows the help text to be captured and processed as part of the program's + /// structured output, which is useful when integrating with external tools or + /// when the output needs to be further transformed. WriteToRenderResult, - /// Print directly + /// Print help information directly to stdout. + /// + /// This is the default behavior, which prints help text immediately to the terminal + /// without any intermediate processing or capture. #[default] PrintDirectly, } -- cgit