From dbaf5dcd30e96bee625698f42d02fb478d38738f Mon Sep 17 00:00:00 2001 From: Uwe Seimet <48174652+uweseimet@users.noreply.github.com> Date: Thu, 21 Oct 2021 02:55:48 +0200 Subject: [PATCH] rasctl output update (#357) --- src/raspberrypi/rasutil.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/raspberrypi/rasutil.cpp b/src/raspberrypi/rasutil.cpp index f464aeba..4b37e6cc 100644 --- a/src/raspberrypi/rasutil.cpp +++ b/src/raspberrypi/rasutil.cpp @@ -41,9 +41,9 @@ string ras_util::ListDevices(const list& pb_devices) } ostringstream s; - s << "+----+----+------+-------------------------------------" << endl - << "| ID | UN | TYPE | DEVICE STATUS" << endl - << "+----+----+------+-------------------------------------" << endl; + s << "+----+-----+------+-------------------------------------" << endl + << "| ID | LUN | TYPE | IMAGE FILE" << endl + << "+----+-----+------+-------------------------------------" << endl; list devices = pb_devices; devices.sort([](const auto& a, const auto& b) { return a.id() < b.id() && a.unit() < b.unit(); }); @@ -64,13 +64,13 @@ string ras_util::ListDevices(const list& pb_devices) break; } - s << "| " << device.id() << " | " << device.unit() << " | " << PbDeviceType_Name(device.type()) << " | " + s << "| " << device.id() << " | " << device.unit() << " | " << PbDeviceType_Name(device.type()) << " | " << (filename.empty() ? "NO MEDIA" : filename) - << (!device.status().removed() && (device.properties().read_only() || device.status().protected_()) ? " (WRITEPROTECT)" : "") + << (!device.status().removed() && (device.properties().read_only() || device.status().protected_()) ? " (READ-ONLY)" : "") << endl; } - s << "+----+----+------+-------------------------------------"; + s << "+----+-----+------+-------------------------------------"; return s.str(); }