Skip to content

Commit 18031c2

Browse files
stepanchegfacebook-github-bot
authored andcommitted
No files, no --evaluate when --lsp or --dap
Reviewed By: ndmitchell Differential Revision: D36237223 fbshipit-source-id: 75385ec2c19afa900733e00a406021efe4486a16
1 parent 5c19884 commit 18031c2

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

starlark/bin/main.rs

+12-3
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,11 @@ struct Args {
7373
)]
7474
check: bool,
7575

76-
#[structopt(long = "json", help = "Show output as JSON lines.")]
76+
#[structopt(
77+
long = "json",
78+
help = "Show output as JSON lines.",
79+
conflicts_with_all = &["lsp", "dap"],
80+
)]
7781
json: bool,
7882

7983
#[structopt(
@@ -89,11 +93,16 @@ struct Args {
8993
long = "expression",
9094
short = "e",
9195
name = "EXPRESSION",
92-
help = "Expressions to evaluate."
96+
help = "Expressions to evaluate.",
97+
conflicts_with_all = &["lsp", "dap"],
9398
)]
9499
evaluate: Vec<String>,
95100

96-
#[structopt(name = "FILE", help = "Files to evaluate.")]
101+
#[structopt(
102+
name = "FILE",
103+
help = "Files to evaluate.",
104+
conflicts_with_all = &["lsp", "dap"],
105+
)]
97106
files: Vec<PathBuf>,
98107
}
99108

0 commit comments

Comments
 (0)