On Tue, Mar 11, 2014 at 04:59:18PM +0100, Pino Toscano wrote:
Just like the other --list output formats provide the architecture,
show
them also in the short format.
---
builder/list_entries.ml | 2 ++
builder/test-virt-builder-list.sh | 14 +++++++-------
2 files changed, 9 insertions(+), 7 deletions(-)
diff --git a/builder/list_entries.ml b/builder/list_entries.ml
index 623040a..2c600d5 100644
--- a/builder/list_entries.ml
+++ b/builder/list_entries.ml
@@ -30,9 +30,11 @@ let rec list_entries ~list_format ~sources index =
and list_entries_short index =
List.iter (
fun (name, { Index_parser.printable_name = printable_name;
+ arch = arch;
hidden = hidden }) ->
if not hidden then (
printf "%-24s" name;
+ printf " %-10s" arch;
(match printable_name with
| None -> ()
| Some s -> printf " %s" s
diff --git a/builder/test-virt-builder-list.sh b/builder/test-virt-builder-list.sh
index 2f9b319..1f62838 100755
--- a/builder/test-virt-builder-list.sh
+++ b/builder/test-virt-builder-list.sh
@@ -27,13 +27,13 @@ export XDG_CONFIG_DIRS="$abs_builddir/test-config"
short_list=$($VG ./virt-builder --no-check-signature --no-cache --list)
-if [ "$short_list" != "phony-debian Phony Debian
-phony-fedora Phony Fedora
-phony-fedora-qcow2 Phony Fedora qcow2
-phony-fedora-qcow2-uncompressed Phony Fedora qcow2 uncompressed
-phony-fedora-no-format Phony Fedora
-phony-ubuntu Phony Ubuntu
-phony-windows Phony Windows" ]; then
+if [ "$short_list" != "phony-debian x86_64 Phony Debian
+phony-fedora x86_64 Phony Fedora
+phony-fedora-qcow2 x86_64 Phony Fedora qcow2
+phony-fedora-qcow2-uncompressed x86_64 Phony Fedora qcow2 uncompressed
+phony-fedora-no-format x86_64 Phony Fedora
+phony-ubuntu x86_64 Phony Ubuntu
+phony-windows x86_64 Phony Windows" ]; then
echo "$0: unexpected --list output:"
echo "$short_list"
exit 1
--
1.8.3.1
I think this was ACKed already? In any case, ACK.
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
libguestfs lets you edit virtual machines. Supports shell scripting,
bindings from many languages.
http://libguestfs.org