Bail on zero-arg :help invocation

This commit is contained in:
Michael Davis 2022-12-12 20:06:07 -06:00
parent 321fce3ba6
commit 816dfee64a
No known key found for this signature in database

View File

@ -1813,10 +1813,8 @@ fn help(cx: &mut compositor::Context, args: &[Cow<str>], event: PromptEvent) ->
return Ok(());
}
if args.is_empty() {
// TODO: Open a list of commands?
todo!()
}
// TODO: Open a list of commands / overview?
ensure!(!args.is_empty(), "Help topic or keybind required");
if args[0] == "topics" {
let dir_path = helix_loader::runtime_dir().join("help/topics");