提交 d0b8bc85 编写于 作者: P Peter Krempa

virsh: Reformat output of virsh net-list

This patch changes whitespace and the length of the separation line from
this format:

$ virsh net-list --all
Name                 State      Autostart     Persistent
--------------------------------------------------
default              inactive   yes           yes

to

$ virsh net-list --all
 Name                 State      Autostart     Persistent
----------------------------------------------------------
 default              inactive   yes           yes

to match the output of virsh list.
上级 bb19491c
......@@ -614,9 +614,10 @@ cmdNetworkList(vshControl *ctl, const vshCmd *cmd ATTRIBUTE_UNUSED)
if (!(list = vshNetworkListCollect(ctl, flags)))
return false;
vshPrintExtra(ctl, "%-20s %-10s %-13s %s\n", _("Name"), _("State"),
vshPrintExtra(ctl, " %-20s %-10s %-13s %s\n", _("Name"), _("State"),
_("Autostart"), _("Persistent"));
vshPrintExtra(ctl, "--------------------------------------------------\n");
vshPrintExtra(ctl,
"----------------------------------------------------------\n");
for (i = 0; i < list->nnets; i++) {
virNetworkPtr network = list->nets[i];
......@@ -628,7 +629,7 @@ cmdNetworkList(vshControl *ctl, const vshCmd *cmd ATTRIBUTE_UNUSED)
else
autostartStr = is_autostart ? _("yes") : _("no");
vshPrint(ctl, "%-20s %-10s %-13s %s\n",
vshPrint(ctl, " %-20s %-10s %-13s %s\n",
virNetworkGetName(network),
virNetworkIsActive(network) ? _("active") : _("inactive"),
autostartStr,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册