diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-06-27 18:28:52 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-06-27 18:28:52 +0800 |
| commit | 5a23e6b3ad655b15b412720ab81b0508866bebce (patch) | |
| tree | 3e68af0c8afc17e545714f8f0fb7703d34a20244 /mingling_core/src/program/config.rs | |
| parent | 4f7bd4f6fa5d27cfe703c54aa029a321f40d19fb (diff) | |
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
Diffstat (limited to 'mingling_core/src/program/config.rs')
| -rw-r--r-- | mingling_core/src/program/config.rs | 12 |
1 files changed, 10 insertions, 2 deletions
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, } |
