From 471a67cd6bb133267e9e26ee0c4a6a934299253f Mon Sep 17 00:00:00 2001 From: Joursoir Date: Wed, 31 Aug 2022 16:13:00 +0300 Subject: exec-cmd: use angle brackets to show that argument should be replaced The angle brackets (<>) indicate that the enclosed parameter is mandatory. Man syntax uses italic text for this purpose, but our text is unformatted, so we use characters. --- src/exec-cmd.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/src/exec-cmd.c b/src/exec-cmd.c index 1bfc3ff..a54e67e 100644 --- a/src/exec-cmd.c +++ b/src/exec-cmd.c @@ -38,7 +38,7 @@ int cmd_init(int argc, char *argv[]) { - const char description[] = "init gpg-key\n"; + const char description[] = "init \n"; int retval = 0, result; char *gpg_key = argv[2]; if(gpg_key == NULL) { @@ -67,7 +67,7 @@ int cmd_init(int argc, char *argv[]) int cmd_insert(int argc, char *argv[]) { - const char description[] = "insert [-ecf] passname\n"; + const char description[] = "insert [-ecf] \n"; int retval = 0, result; int flag_echo = 0, flag_force = 0, flag_copy = 0; const struct option long_options[] = { @@ -162,7 +162,7 @@ out: int cmd_edit(int argc, char *argv[]) { - const char description[] = "edit passname\n"; + const char description[] = "edit \n"; int result, fd, pid, len_pass, save_errno; /* We expect tmpfs to be mounted at /dev/shm */ char path_tmpfile[] = "/dev/shm/lpass.XXXXXX"; @@ -266,7 +266,7 @@ int cmd_edit(int argc, char *argv[]) int cmd_generate(int argc, char *argv[]) { - const char description[] = "generate [-l=pass-length] [-f] passname\n"; + const char description[] = "generate [-l=pass-length] [-f] \n"; int pass_length = stdlen_pass; int flag_force = 0, flag_copy = 0, result; const struct option long_options[] = { @@ -336,7 +336,7 @@ int cmd_generate(int argc, char *argv[]) int cmd_remove(int argc, char *argv[]) { - const char description[] = "rm passname\n"; + const char description[] = "rm \n"; int result; char *path = argv[1]; if(!path) { @@ -374,7 +374,7 @@ int cmd_move(int argc, char *argv[]) 1) mv file file 2) mv file directory */ - const char description[] = "mv [-f] old-path new-path\n"; + const char description[] = "mv [-f] \n"; const struct option long_options[] = { {"force", no_argument, NULL, 'f'}, {NULL, 0, NULL, 0} @@ -433,23 +433,23 @@ int cmd_move(int argc, char *argv[]) int cmd_help(int argc, char *argv[]) { printf("Synopsis:\n" - "\tlpass command [arguments] ...\n" + "\tlpass [arguments] ...\n" "Commands:\n" - "\tinit gpg-key\n" + "\tinit \n" "\t\tInitialize the password manager using the passed gpg-key.\n" - "\tinsert [-e, --echo] [-c, --copy] [-f, --force] passname\n" + "\tinsert [-e, --echo] [-c, --copy] [-f, --force] \n" "\t\tAdd the specified passname to the password manager.\n" "\tshow [-c, --copy] [-C, --no-color] [passname]\n" "\t\tIf the specified passname is file, decrypt and print a password of passname. " "Otherwise list passnames inside the tree at passname.\n" - "\tedit [-t, --text-editor=text-editor] passname\n" + "\tedit [-t, --text-editor=text-editor] \n" "\t\tOpen the specified passname in a text editor, waiting for changes.\n" - "\tgenerate [-l, --length=pass-length] [-c, --copy] [-f, --force] passname\n" + "\tgenerate [-l, --length=pass-length] [-c, --copy] [-f, --force] \n" "\t\tGenerate a random password and write it in passname.\n" - "\tmv [-f, --force] old-path new-path\n" + "\tmv [-f, --force] \n" "\t\tMove/rename old-path to new-path.\n" - "\trm passname\n" + "\trm \n" "\t\tRemove the passname you specified from the password manager.\n" "\thelp\n" "\t\tPrint help information about commands and the application itself.\n" -- cgit v1.2.3-18-g5258