1use std::path::PathBuf;
2
3use clap::Parser;
4
5#[derive(Parser, Debug)]
7#[command(version, about, long_about = None )]
8pub struct CliArgs {
9 pub(crate) root: Option<PathBuf>,
11
12 #[arg(
18 short = 'w',
19 long = "where",
20 value_name = "FILTER",
21 visible_alias = "filter",
22 help_heading = "Filtering Options"
23 )]
24 pub(crate) filter: Vec<String>,
25
26 #[arg(
32 short,
33 long,
34 value_name = "ORDER BY",
35 visible_alias = "sort",
36 visible_alias = "order",
37 visible_alias = "sort-by",
38 help_heading = "Output Ordering"
39 )]
40 pub(crate) order_by: Option<String>,
41
42 #[arg(short = 'x', long, help_heading = "Filtering Options")]
44 pub(crate) max_depth: Option<usize>,
45
46 #[arg(short = 'n', long, help_heading = "Filtering Options")]
48 pub(crate) min_depth: Option<usize>,
49
50 #[arg(short, long, help_heading = "Filtering Options")]
52 pub(crate) limit: Option<usize>,
53
54 #[arg(
59 short,
60 long,
61 visible_alias = "show",
62 visible_alias = "print",
63 value_name = "DISPLAY",
64 help_heading = "Output Formatting"
65 )]
66 pub(crate) display: Option<String>,
67
68 #[arg(
70 long,
71 default_value = "`",
72 visible_alias = "expr-start",
73 help_heading = "Output Formatting"
74 )]
75 pub(crate) interpolation_start: String,
76
77 #[arg(
79 long,
80 default_value = "`",
81 visible_alias = "expr-end",
82 help_heading = "Output Formatting"
83 )]
84 pub(crate) interpolation_end: String,
85
86 #[arg(
88 long,
89 default_value_t = false,
90 visible_alias = "files-first",
91 visible_alias = "depth-first",
92 help_heading = "Output Ordering"
93 )]
94 pub(crate) node_first: bool,
95
96 #[arg(
98 long,
99 value_name = "DEBUG_FILE",
100 visible_alias = "debug-log",
101 help_heading = "Developer Options"
102 )]
103 pub(crate) debug_output_file: Option<PathBuf>,
104
105 #[arg(long, help_heading = "Developer Options")]
107 pub(crate) help_syntax: bool,
108}