Skip to content

Commit b81f7cf

Browse files
fix: Update argument documentation and handling in repl (#6979)
- Updated argument descriptions in help for import-keys, createbroadcast, and groupimage. - Revised import-keys to check for the required argument.
1 parent 9197ef0 commit b81f7cf

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

deltachat-repl/src/cmdline.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,7 @@ pub async fn cmdline(context: Context, line: &str, chat_id: &mut ChatId) -> Resu
324324
send-backup\n\
325325
receive-backup <qr>\n\
326326
export-keys\n\
327-
import-keys\n\
327+
import-keys <key-file>\n\
328328
poke [<eml-file>|<folder>|<addr> <key-file>]\n\
329329
reset <flags>\n\
330330
stop\n\
@@ -352,12 +352,12 @@ pub async fn cmdline(context: Context, line: &str, chat_id: &mut ChatId) -> Resu
352352
chat [<chat-id>|0]\n\
353353
createchat <contact-id>\n\
354354
creategroup <name>\n\
355-
createbroadcast\n\
355+
createbroadcast <name>\n\
356356
createprotected <name>\n\
357357
addmember <contact-id>\n\
358358
removemember <contact-id>\n\
359359
groupname <name>\n\
360-
groupimage [<file>]\n\
360+
groupimage <image>\n\
361361
chatinfo\n\
362362
sendlocations <seconds>\n\
363363
setlocation <lat> <lng>\n\
@@ -489,6 +489,7 @@ pub async fn cmdline(context: Context, line: &str, chat_id: &mut ChatId) -> Resu
489489
println!("Exported to {}.", dir.to_string_lossy());
490490
}
491491
"import-keys" => {
492+
ensure!(!arg1.is_empty(), "Argument <key-file> missing.");
492493
imex(&context, ImexMode::ImportSelfKeys, arg1.as_ref(), None).await?;
493494
}
494495
"poke" => {

0 commit comments

Comments
 (0)