Skip to content

Commit bacd889

Browse files
committed
run chat on any arg being help
1 parent a724d0c commit bacd889

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

crates/q_cli/src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ fn main() -> Result<ExitCode> {
4242
.build()?;
4343

4444
// Hack as clap doesn't expose a custom command help.
45-
if subcommand.as_deref() == Some("chat") && args.next().as_deref() == Some("--help") {
45+
if subcommand.as_deref() == Some("chat") && args.any(|arg| ["--help", "-h"].contains(&arg.as_str())) {
4646
runtime.block_on(cli::Cli::execute_chat(Some(vec!["--help".to_owned()]), true))?;
4747
}
4848

0 commit comments

Comments
 (0)