mirror of https://gerrit.osmocom.org/libosmocore
vty/show asciidoc: add user readable description of the version
Change-Id: Ie0f1b3894361c58386da9defb225979fa0ee6a18
This commit is contained in:
parent
27a35ed47c
commit
e052dc285d
|
@ -41,6 +41,9 @@
|
||||||
|
|
||||||
#define SHOW_STATS_STR "Show statistical values\n"
|
#define SHOW_STATS_STR "Show statistical values\n"
|
||||||
|
|
||||||
|
/* containing version info */
|
||||||
|
extern struct host host;
|
||||||
|
|
||||||
struct cmd_node cfg_stats_node = {
|
struct cmd_node cfg_stats_node = {
|
||||||
CFG_STATS_NODE,
|
CFG_STATS_NODE,
|
||||||
"%s(config-stats)# ",
|
"%s(config-stats)# ",
|
||||||
|
@ -484,6 +487,13 @@ DEFUN(show_stats_asciidoc_table,
|
||||||
"show asciidoc counters",
|
"show asciidoc counters",
|
||||||
SHOW_STR "Asciidoc generation\n" "Generate table of all registered counters\n")
|
SHOW_STR "Asciidoc generation\n" "Generate table of all registered counters\n")
|
||||||
{
|
{
|
||||||
|
vty_out(vty, "// autogenerated by show asciidoc counters%s", VTY_NEWLINE);
|
||||||
|
vty_out(vty, "These counters and their description based on %s %s (%s).%s%s",
|
||||||
|
host.app_info->name,
|
||||||
|
host.app_info->version,
|
||||||
|
host.app_info->name ? host.app_info->name : "", VTY_NEWLINE, VTY_NEWLINE);
|
||||||
|
/* 2x VTY_NEWLINE are intentional otherwise it would interpret the first table header
|
||||||
|
* as usual text*/
|
||||||
vty_out(vty, "// generating tables for rate_ctr_group%s", VTY_NEWLINE);
|
vty_out(vty, "// generating tables for rate_ctr_group%s", VTY_NEWLINE);
|
||||||
rate_ctr_for_each_group(asciidoc_rate_ctr_group_handler, vty);
|
rate_ctr_for_each_group(asciidoc_rate_ctr_group_handler, vty);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue