diff --git a/libr/include/r_io.h b/libr/include/r_io.h index eebb38c7ee..dd77c6c77c 100644 --- a/libr/include/r_io.h +++ b/libr/include/r_io.h @@ -170,6 +170,8 @@ typedef struct r_io_plugin_t { // void *plugin; char *name; char *desc; + char *version; + char *author; char *license; void *widget; int (*listener)(RIODesc *io); diff --git a/libr/include/r_lib.h b/libr/include/r_lib.h index 653bd99c44..a313dee56f 100644 --- a/libr/include/r_lib.h +++ b/libr/include/r_lib.h @@ -33,6 +33,8 @@ typedef struct r_lib_plugin_t { void *data; /* user pointer */ struct r_lib_handler_t *handler; void *dl_handler; // DL HANDLER + char *author; + char *version; } RLibPlugin; /* store list of initialized plugin handlers */ diff --git a/libr/io/p/io_debug.c b/libr/io/p/io_debug.c index fb75e85aef..7bcbe6deec 100644 --- a/libr/io/p/io_debug.c +++ b/libr/io/p/io_debug.c @@ -462,6 +462,8 @@ RIOPlugin r_io_plugin_debug = { .name = "debug", .desc = "Native debugger (dbg:///bin/ls dbg://1388 pidof:// waitfor://)", .license = "LGPL3", + .author = "pancake", + .version = "0.1.0", .open = __open, .check = __plugin_open, .isdbg = true, diff --git a/libr/io/plugin.c b/libr/io/plugin.c index 10d9f5f43f..7a9e502c78 100644 --- a/libr/io/plugin.c +++ b/libr/io/plugin.c @@ -1,4 +1,4 @@ -/* radare - LGPL - Copyright 2008-2016 - pancake */ +/* radare - LGPL - Copyright 2008-2017 - pancake */ /* TODO: write li->fds setter/getter helpers */ // TODO: return true/false everywhere,, not -1 or 0 @@ -86,8 +86,16 @@ R_API int r_io_plugin_list(RIO *io) { str[1] = plugin->write ? 'w' : '_'; str[2] = plugin->isdbg ? 'd' : '_'; str[3] = 0; - io->cb_printf ("%s %-8s %s (%s)\n", str, plugin->name, + io->cb_printf ("%s %-8s %s (%s)", + str, plugin->name, plugin->desc, plugin->license); + if (plugin->version) { + io->cb_printf (" v%s", plugin->version); + } + if (plugin->author) { + io->cb_printf (" %s", plugin->author); + } + io->cb_printf ("\n"); n++; } return n;