Skip to content
Snippets Groups Projects
Commit bd156836 authored by Alex Xu (Hello71)'s avatar Alex Xu (Hello71) Committed by Timo Teräs
Browse files

add: warn when creating empty virtual packages

see alpine/aports#11736

[TT: minor stylistic change]
parent 9b3e68d4
No related branches found
No related tags found
No related merge requests found
......@@ -147,6 +147,8 @@ static int add_main(void *ctx, struct apk_ctx *ac, struct apk_string_array *args
virtdep.result_mask = APK_VERSION_EQUAL;
virtdep.version = virtpkg->version;
if (!args->num) apk_warn(out, "creating empty virtual package");
}
foreach_array_item(parg, args) {
......
......@@ -2,5 +2,6 @@
--no-network
add -t .virtual
@EXPECT
WARNING: creating empty virtual package
(1/1) Installing .virtual (20190603.131426)
OK: 0 MiB in 0 packages
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment