diff options
author | Toyam Cox <Vaelatern@gmail.com> | 2016-03-21 23:49:14 -0400 |
---|---|---|
committer | Christian Neukirchen <chneukirchen@gmail.com> | 2016-03-22 15:00:48 +0100 |
commit | 82a4415efdd8f3536885782ffe2b8e3378a04a63 (patch) | |
tree | f267fef67ab9876422a62f9a1a460e985084c7df /xsubpkg | |
parent | 4deb083dedd36cd91009267a8607256af6ccbe69 (diff) | |
download | xtools-82a4415efdd8f3536885782ffe2b8e3378a04a63.tar.gz xtools-82a4415efdd8f3536885782ffe2b8e3378a04a63.tar.xz xtools-82a4415efdd8f3536885782ffe2b8e3378a04a63.zip |
xsubpkg: add flag to only show main package
Closes: #37 [via git-merge-pr]
Diffstat (limited to 'xsubpkg')
-rwxr-xr-x | xsubpkg | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/xsubpkg b/xsubpkg index 1cb9066..ce236cf 100755 --- a/xsubpkg +++ b/xsubpkg @@ -1,6 +1,12 @@ #!/bin/sh -# xsubpkg PKG - lists all subpackages of a package +# xsubpkg [-m] PKG - lists all subpackages of a package + +followsym="-L" + +case "$1" in + -m) followsym="-P"; shift +esac PKG=$1 cd $(xdistdir) -find -L srcpkgs -maxdepth 2 -samefile srcpkgs/"$PKG"/template | cut -d/ -f 2 +find $followsym srcpkgs -maxdepth 2 -samefile srcpkgs/"$PKG"/template | cut -d/ -f 2 |