aboutsummaryrefslogtreecommitdiff
path: root/mingling_core/src/program
diff options
context:
space:
mode:
Diffstat (limited to 'mingling_core/src/program')
-rw-r--r--mingling_core/src/program/collection.rs2
-rw-r--r--mingling_core/src/program/collection/mock.rs2
-rw-r--r--mingling_core/src/program/config.rs24
-rw-r--r--mingling_core/src/program/hook.rs2
-rw-r--r--mingling_core/src/program/once_exec.rs4
5 files changed, 29 insertions, 5 deletions
diff --git a/mingling_core/src/program/collection.rs b/mingling_core/src/program/collection.rs
index 0a37106..2b3e9ec 100644
--- a/mingling_core/src/program/collection.rs
+++ b/mingling_core/src/program/collection.rs
@@ -8,7 +8,7 @@ use crate::Dispatcher;
use crate::{AnyOutput, ChainProcess, Grouped, RenderResult};
#[cfg(feature = "structural_renderer")]
-use crate::{StructuralRendererSetting, error::StructuralRendererSerializeError};
+use crate::{config::StructuralRendererSetting, error::StructuralRendererSerializeError};
#[cfg(feature = "comp")]
use crate::{ShellContext, Suggest};
diff --git a/mingling_core/src/program/collection/mock.rs b/mingling_core/src/program/collection/mock.rs
index 634d529..6b4406e 100644
--- a/mingling_core/src/program/collection/mock.rs
+++ b/mingling_core/src/program/collection/mock.rs
@@ -10,7 +10,7 @@ use crate::Dispatcher;
use crate::{ShellContext, Suggest};
#[cfg(feature = "structural_renderer")]
-use crate::{StructuralRendererSetting, error::StructuralRendererSerializeError};
+use crate::{config::StructuralRendererSetting, error::StructuralRendererSerializeError};
#[cfg(feature = "structural_renderer")]
use serde::Serialize;
diff --git a/mingling_core/src/program/config.rs b/mingling_core/src/program/config.rs
index 86b8c23..dae3f0a 100644
--- a/mingling_core/src/program/config.rs
+++ b/mingling_core/src/program/config.rs
@@ -1,4 +1,28 @@
// Doc Not Optimize
+
+//! Config module for program output settings and user context.
+//!
+//! This module provides configuration types and settings for controlling
+//! how the program outputs errors, rendered results, panic messages,
+//! verbosity levels, colors, progress indicators, and other user-defined
+//! context values used throughout the program lifecycle.
+//!
+//! The module includes the following items:
+//! - [`ErrorOutput`]: Output mode for error messages.
+//! - [`RenderOutput`]: Output mode for rendered results.
+//! - [`PanicSilence`]: Panic message handling.
+//! - [`Verbosity`]: Verbosity level for program output.
+//! - [`ColorOutput`]: Color output mode.
+//! - [`ProgressOutput`]: Progress indicator mode.
+//! - [`ProgramStdoutSetting`]: Program stdout settings.
+//! - [`ClapHelpPrintBehaviour`]: Behavior when Clap Dispatcher outputs help information.
+//! - [`ConfirmationMode`]: Confirmation mode for user prompts.
+//! - [`ExecutionMode`]: Execution mode.
+//! - [`InteractionMode`]: Interaction mode.
+//! - [`YesAssumption`]: Yes assumption mode for prompts.
+//! - [`ProgramUserContext`]: Program user context.
+//! - [`StructuralRendererSetting`]: Settings for the structural renderer output format.
+
/// Output mode for error messages
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum ErrorOutput {
diff --git a/mingling_core/src/program/hook.rs b/mingling_core/src/program/hook.rs
index cb8e4e1..8fd2ba1 100644
--- a/mingling_core/src/program/hook.rs
+++ b/mingling_core/src/program/hook.rs
@@ -768,7 +768,7 @@ mod tests {
#[cfg(feature = "structural_renderer")]
fn structural_render(
_any: crate::AnyOutput<Self>,
- _setting: &crate::StructuralRendererSetting,
+ _setting: &crate::config::StructuralRendererSetting,
) -> Result<crate::RenderResult, crate::error::StructuralRendererSerializeError> {
unreachable!()
}
diff --git a/mingling_core/src/program/once_exec.rs b/mingling_core/src/program/once_exec.rs
index b1fba36..e9927b5 100644
--- a/mingling_core/src/program/once_exec.rs
+++ b/mingling_core/src/program/once_exec.rs
@@ -99,7 +99,7 @@ where
// Read exit code
// Render result
- if stdout_setting.render_output == crate::RenderOutput::Show {
+ if stdout_setting.render_output == crate::config::RenderOutput::Show {
result.std_print();
}
@@ -163,7 +163,7 @@ where
.unwrap();
#[cfg(not(panic = "abort"))]
- if program.stdout_setting.silence_panic == super::PanicSilence::Silence {
+ if program.stdout_setting.silence_panic == super::config::PanicSilence::Silence {
std::panic::set_hook(Box::new(|_| {}));
}