aboutsummaryrefslogtreecommitdiff
path: root/mingling/src/setups/picker/consts.rs
blob: e254b4ffb09e2ae3ade188b54c4f39aafd1cd158 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
use std::marker::PhantomData;

use arg_picker::{PickerArg, value::Flag};

/// Help flag: display usage information.
/// - `full`: `["help"]`
/// - `short`: `'h'`
pub const HELP_FLAG: PickerArg<Flag> = PickerArg::<Flag> {
    full: &["help"],
    short: Some('h'),
    positional: false,
    internal_type: PhantomData,
};

/// Quiet flag: suppress output.
/// - `full`: `["quiet"]`
/// - `short`: `'q'`
pub const QUIET_FLAG: PickerArg<Flag> = PickerArg::<Flag> {
    full: &["quiet"],
    short: Some('q'),
    positional: false,
    internal_type: PhantomData,
};

/// Confirm flag: require user confirmation before proceeding.
/// - `full`: `["confirm"]`
/// - `short`: `'C'`
pub const CONFIRM_FLAG: PickerArg<Flag> = PickerArg::<Flag> {
    full: &["confirm"],
    short: Some('C'),
    positional: false,
    internal_type: PhantomData,
};

/// JSON flag: enable JSON output format.
/// - `full`: `["json"]`
/// - `short`: (none)
///   Available only when the `json_serde_fmt` feature is enabled.
#[cfg(feature = "json_serde_fmt")]
pub const JSON_FLAG: PickerArg<Flag> = PickerArg::<Flag> {
    full: &["json"],
    short: None,
    positional: false,
    internal_type: PhantomData,
};

/// JSON pretty flag: enable pretty-printed JSON output format.
/// - `full`: `["json_pretty"]`
/// - `short`: (none)
///   Available only when the `json_serde_fmt` feature is enabled.
#[cfg(feature = "json_serde_fmt")]
pub const JSON_PRETTY_FLAG: PickerArg<Flag> = PickerArg::<Flag> {
    full: &["json_pretty"],
    short: None,
    positional: false,
    internal_type: PhantomData,
};

/// YAML flag: enable YAML output format.
/// - `full`: `["yaml"]`
/// - `short`: (none)
///   Available only when the `yaml_serde_fmt` feature is enabled.
#[cfg(feature = "yaml_serde_fmt")]
pub const YAML_FLAG: PickerArg<Flag> = PickerArg::<Flag> {
    full: &["yaml"],
    short: None,
    positional: false,
    internal_type: PhantomData,
};

/// TOML flag: enable TOML output format.
/// - `full`: `["toml"]`
/// - `short`: (none)
///   Available only when the `toml_serde_fmt` feature is enabled.
#[cfg(feature = "toml_serde_fmt")]
pub const TOML_FLAG: PickerArg<Flag> = PickerArg::<Flag> {
    full: &["toml"],
    short: None,
    positional: false,
    internal_type: PhantomData,
};

/// RON flag: enable RON output format.
/// - `full`: `["ron"]`
/// - `short`: (none)
///   Available only when the `ron_serde_fmt` feature is enabled.
#[cfg(feature = "ron_serde_fmt")]
pub const RON_FLAG: PickerArg<Flag> = PickerArg::<Flag> {
    full: &["ron"],
    short: None,
    positional: false,
    internal_type: PhantomData,
};

/// RON pretty flag: enable pretty-printed RON output format.
/// - `full`: `["ron_pretty"]`
/// - `short`: (none)
///   Available only when the `ron_serde_fmt` feature is enabled.
#[cfg(feature = "ron_serde_fmt")]
pub const RON_PRETTY_FLAG: PickerArg<Flag> = PickerArg::<Flag> {
    full: &["ron_pretty"],
    short: None,
    positional: false,
    internal_type: PhantomData,
};