aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mingling/src/setups/basic.rs26
-rw-r--r--mingling/src/setups/structural_renderer.rs14
-rw-r--r--mling/src/cli.rs3
3 files changed, 43 insertions, 0 deletions
diff --git a/mingling/src/setups/basic.rs b/mingling/src/setups/basic.rs
index 6a69733..e081c3e 100644
--- a/mingling/src/setups/basic.rs
+++ b/mingling/src/setups/basic.rs
@@ -1,3 +1,5 @@
+#![allow(deprecated)]
+
use mingling_core::{Flag, Program, ProgramCollect, setup::ProgramSetup};
/// Performs basic program initialization:
@@ -5,6 +7,12 @@ use mingling_core::{Flag, Program, ProgramCollect, setup::ProgramSetup};
/// - Collects `--quiet` flag to control message rendering
/// - Collects `--help` flag to enable help mode
/// - Collects `--confirm` flag to skip user confirmation
+#[cfg_attr(
+ feature = "picker",
+ deprecated(
+ note = "When the `picker` feature is enabled, you can use `mingling::setup::picker::BasicProgramSetup` instead"
+ )
+)]
pub struct BasicProgramSetup;
impl<C> ProgramSetup<C> for BasicProgramSetup
@@ -21,6 +29,12 @@ where
/// Provides setup for parsing the user help flag
///
/// The default value is `--help / -h`
+#[cfg_attr(
+ feature = "picker",
+ deprecated(
+ note = "When the `picker` feature is enabled, you can use `mingling::setup::picker::HelpFlagSetup` instead"
+ )
+)]
pub struct HelpFlagSetup {
flag: Flag,
}
@@ -54,6 +68,12 @@ impl Default for HelpFlagSetup {
/// Provides setup for parsing the quiet flag
///
/// The default value is `--quiet / -q`
+#[cfg_attr(
+ feature = "picker",
+ deprecated(
+ note = "When the `picker` feature is enabled, you can use `mingling::setup::picker::QuietFlagSetup` instead"
+ )
+)]
pub struct QuietFlagSetup {
flag: Flag,
}
@@ -88,6 +108,12 @@ impl Default for QuietFlagSetup {
/// Provides setup for parsing the confirm flag
///
/// The default value is `--confirm / -C`
+#[cfg_attr(
+ feature = "picker",
+ deprecated(
+ note = "When the `picker` feature is enabled, you can use `mingling::setup::picker::ConfirmFlagSetup` instead"
+ )
+)]
pub struct ConfirmFlagSetup {
flag: Flag,
}
diff --git a/mingling/src/setups/structural_renderer.rs b/mingling/src/setups/structural_renderer.rs
index af3ed91..0ab2347 100644
--- a/mingling/src/setups/structural_renderer.rs
+++ b/mingling/src/setups/structural_renderer.rs
@@ -1,8 +1,16 @@
+#![allow(deprecated)]
+
use mingling_core::{Program, ProgramCollect, setup::ProgramSetup};
/// Sets up the structural renderer for the program:
///
/// - Adds a `--renderer` global argument to specify the renderer type
+#[cfg_attr(
+ feature = "picker",
+ deprecated(
+ note = "When the `picker` feature is enabled, you can use `mingling::setup::picker::StructuralRendererSimpleSetup` instead"
+ )
+)]
pub struct StructuralRendererSimpleSetup;
impl<C> ProgramSetup<C> for StructuralRendererSimpleSetup
@@ -25,6 +33,12 @@ where
/// * `--toml` for TOML output
/// * `--ron` for RON output
/// * `--ron-pretty` for pretty-printed RON output
+#[cfg_attr(
+ feature = "picker",
+ deprecated(
+ note = "When the `picker` feature is enabled, you can use `mingling::setup::picker::StructuralRendererSetup` instead"
+ )
+)]
pub struct StructuralRendererSetup;
impl<C> ProgramSetup<C> for StructuralRendererSetup
diff --git a/mling/src/cli.rs b/mling/src/cli.rs
index 67d2ef0..45a49d0 100644
--- a/mling/src/cli.rs
+++ b/mling/src/cli.rs
@@ -1,3 +1,6 @@
+// `mling` has not been replaced from `parser` to `picker` yet
+#![allow(deprecated)]
+
use crate::{
CMDCompletion, ErrorDispatcherNotFound, Next, ThisProgram,
display::markdown,