commit 21891002a2e3c60320aa8aead5856a6c7cc88a86
parent 6a104ac5913a6e9effedf462fb50b49c17c7d4ed
Author: Cem Keylan <cem@ckyln.com>
Date: Mon, 22 Feb 2021 15:56:17 +0300
pkg_get_base(): return the dependency tree as well
Diffstat:
1 file changed, 6 insertions(+), 0 deletions(-)
diff --git a/src/cpt-lib.in b/src/cpt-lib.in
@@ -1868,6 +1868,12 @@ pkg_get_base() (
while read -r pkgname _; do
[ "${pkgname##\#*}" ] || continue
set -- "$@" "$pkgname"
+ while read -r dep; do
+ contains "$*" "$dep" && continue
+ set -- "$@" "$dep"
+ done <<EOF
+$(pkg_gentree "$pkgname" x)
+EOF
done < "$CPT_ROOT/etc/cpt-base"
if [ "$nonl" ]; then printf '%s ' "$@"; else printf '%s\n' "$@"; fi
)