# option for "multipackage" just to let the system know that's what you meant
# option to take filenames from stdin
# parse package, version, release from file if not given
+# TODO -l follow symlinks, -L follow symlinks, adding all, links and targets
while getopts :f:vr:l:P:S:cu:g: opt; do
case $opt in
f) pkgfile="$OPTARG" ;;
if [ -z "$pkgfile" ]; then
die "cannot determine package file"
else
- pkgstr=$(zpm findpkg $pkgfile $pkgid)
+ pkgstr=$(zpm findpkg -f $pkgfile $pkgid)
if [ -z "$pkgstr" ]; then
die "unable to find package id for $pkgid in $pkgfile"
fi
rpath="$prefix/$rpath"
fi
- filetype=$(zpm stat -f '%t' "$path")
+ filetype=$(zpm stat -l -f '%t' "$path")
hash='NULL'
target='NULL'
case "$filetype" in
EOS
#printf "%s %s%s\n" $path $rpath ${target:+" -> $target"}
-printf "%s\n" $path
+if [ $verbose -gt 0 ]; then
+ printf "%s\n" $path
+fi
+
done