1 2 3 4 5 6 7 8 9 10 11 12
#!/bin/sh # xsubpkg [-m] PKG - lists all subpackages of a package followsym="-L" case "$1" in -m) followsym="-P"; shift esac PKG=$1 cd $(xdistdir) find $followsym srcpkgs -maxdepth 2 -samefile srcpkgs/"$PKG"/template | cut -d/ -f 2