mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-26 12:53:59 +03:00
Efficiency fix for ghc-get-packages script.
svn path=/nixpkgs/trunk/; revision=16326
This commit is contained in:
parent
18ef0d1673
commit
059b912b27
@ -11,11 +11,11 @@ else
|
|||||||
fi
|
fi
|
||||||
PATH="$2:$PATH"
|
PATH="$2:$PATH"
|
||||||
IFS=":"
|
IFS=":"
|
||||||
PKGS=""
|
PKGS=()
|
||||||
for p in $PATH; do
|
for p in $PATH; do
|
||||||
PkgDir="$p/../lib/ghc-pkgs/ghc-$version"
|
PkgDir="$p/../lib/ghc-pkgs/ghc-$version"
|
||||||
for i in $PkgDir/*.installedconf; do
|
for i in $PkgDir/*.installedconf; do
|
||||||
test -f $i && PKGS="$PKGS $prefix$i"
|
test -f $i && PKGS[${#PKGS[*]}]="$prefix$i"
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
echo $PKGS
|
echo ${PKGS[*]}
|
||||||
|
Loading…
Reference in New Issue
Block a user