rusty_commit/output/
prelude.rs1use clap::ValueEnum;
4
5#[derive(Debug, Clone, Copy, Default, ValueEnum)]
7pub enum OutputFormat {
8 #[default]
10 Pretty,
11 Json,
13 Markdown,
15}
16
17#[derive(Debug, Clone, Copy, Default, PartialEq, Eq)]
19#[allow(dead_code)]
20pub enum OutputLevel {
21 Quiet,
23 #[default]
25 Normal,
26 Verbose,
28 Debug,
30}
31
32#[allow(dead_code)]
33impl OutputLevel {
34 pub fn is_verbose_or_higher(&self) -> bool {
35 matches!(self, Self::Verbose | Self::Debug)
36 }
37
38 pub fn is_debug(&self) -> bool {
39 matches!(self, Self::Debug)
40 }
41}