xbps-repo: in the show target also print the binpkg file size.
Now it looks like: ... Filename: kernel-2.6.28.1.i686.xbps (size: 16M) SHA256: 6b2d79ed89697263020979addde7fa2f535d53df0c1b011ea74ec7757cfba2f0 ... --HG-- extra : convert_revision : 3e18cbc35b8a85fffefe71dd64815ba23c06b528
This commit is contained in:
parent
4c70b24941
commit
05f918ea93
|
@ -85,8 +85,21 @@ show_pkg_info(prop_dictionary_t dict)
|
|||
printf("Version: %s\n", prop_string_cstring_nocopy(obj));
|
||||
|
||||
obj = prop_dictionary_get(dict, "filename");
|
||||
if (obj && prop_object_type(obj) == PROP_TYPE_STRING)
|
||||
printf("Filename: %s\n", prop_string_cstring_nocopy(obj));
|
||||
if (obj && prop_object_type(obj) == PROP_TYPE_STRING) {
|
||||
printf("Filename: %s", prop_string_cstring_nocopy(obj));
|
||||
obj = prop_dictionary_get(dict, "filename-size");
|
||||
if (obj && prop_object_type(obj) == PROP_TYPE_NUMBER) {
|
||||
rv = xbps_humanize_number(size, 5,
|
||||
(int64_t)prop_number_unsigned_integer_value(obj),
|
||||
"", HN_AUTOSCALE, HN_NOSPACE);
|
||||
if (rv == -1)
|
||||
printf(" (size: %ju)\n",
|
||||
prop_number_unsigned_integer_value(obj));
|
||||
else
|
||||
printf(" (size: %s)\n", size);
|
||||
} else
|
||||
printf("\n");
|
||||
}
|
||||
|
||||
obj = prop_dictionary_get(dict, "filename-sha256");
|
||||
if (obj && prop_object_type(obj) == PROP_TYPE_STRING)
|
||||
|
|
Loading…
Reference in New Issue