1
0
mirror of https://codeberg.org/kiss-community/kiss synced 2024-12-21 22:50:07 -07:00

kiss-depends: fix pwd

This commit is contained in:
Dylan Araps 2020-09-09 13:40:32 +03:00
parent 53d28cc0a5
commit ba971ba449
No known key found for this signature in database
GPG Key ID: 46D62DD9F1DE636E

View File

@ -1,11 +1,13 @@
#!/bin/sh -ef
# Display a package's dependencies
kiss list "${1:-"${PWD##*/}"}" >/dev/null || {
pkg=${1:-"${PWD##*/}"}
kiss list "$pkg" >/dev/null || {
printf 'usage: kiss-depends [pkg]\n' >&2
exit 1
}
while read -r dep mak || [ "$dep" ]; do
printf '%s%s\n' "$dep" "${mak:+ "$mak"}"
done 2>/dev/null < "$KISS_ROOT/var/db/kiss/installed/$1/depends"
done 2>/dev/null < "$KISS_ROOT/var/db/kiss/installed/$pkg/depends"