Skip to content

Commit 71640c8

Browse files
authored
fix(io): unify R! command usage formatting (#5954)
1 parent 176c071 commit 71640c8

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

librz/io/p/io_gdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ static char *__system(RzIO *io, RzIODesc *fd, const char *cmd) {
215215
return NULL;
216216
}
217217
if (cmd[0] == '?' || !strcmp(cmd, "help")) {
218-
eprintf("Usage: R!cmd args\n"
218+
eprintf("Usage: R!<cmd> [args]\n"
219219
" R!pid - show targeted pid\n"
220220
" R!pkt s - send packet 's'\n"
221221
" R!rd - show reverse debugging availability\n"

librz/io/p/io_ptrace.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -305,7 +305,7 @@ static char *__system(RzIO *io, RzIODesc *fd, const char *cmd) {
305305
return NULL;
306306
}
307307
if (!strcmp(cmd, "help")) {
308-
eprintf("Usage: R!cmd args\n"
308+
eprintf("Usage: R!<cmd> [args]\n"
309309
" R!ptrace - use ptrace io\n"
310310
" R!mem - use /proc/pid/mem io if possible\n"
311311
" R!pid - show targeted pid\n"

librz/io/p/io_self.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -498,16 +498,16 @@ static char *__system(RzIO *io, RzIODesc *fd, const char *cmd) {
498498
io_self->self_sections[i].name);
499499
}
500500
} else {
501-
eprintf("|Usage: R![cmd] [args]\n");
502-
eprintf("| R!pid show getpid()\n");
503-
eprintf("| R!maps show map regions\n");
504-
eprintf("| R!kill commit suicide\n");
501+
eprintf("Usage: R!<cmd> [args]\n");
502+
eprintf(" R!pid show getpid()\n");
503+
eprintf(" R!maps show map regions\n");
504+
eprintf(" R!kill commit suicide\n");
505505
#if !defined(__WINDOWS__)
506-
eprintf("| R!alarm [secs] setup alarm signal to raise rizin prompt\n");
506+
eprintf(" R!alarm [secs] setup alarm signal to raise rizin prompt\n");
507507
#endif
508-
eprintf("| R!dlsym [sym] dlopen\n");
509-
eprintf("| R!call [sym] [...] nativelly call a function\n");
510-
eprintf("| R!mameio enter mame IO mode\n");
508+
eprintf(" R!dlsym [sym] dlopen\n");
509+
eprintf(" R!call [sym] [...] nativelly call a function\n");
510+
eprintf(" R!mameio enter mame IO mode\n");
511511
}
512512
return NULL;
513513
}

0 commit comments

Comments
 (0)