Factor out repeated scriptlets from build-support/release/*.nix.

This commit is contained in:
Petr Rockai
2012-07-23 20:33:04 +02:00
committed by Peter Simons
parent 1eb5450bd4
commit ce77a5ceec
6 changed files with 27 additions and 40 deletions
+14
View File
@@ -0,0 +1,14 @@
findTarballs() {
local suffix
test -d "$1/tarballs/" && {
for suffix in tar.gz tgz tar.bz2 tbz2 tar.xz tar.lzma; do
ls $1/tarballs/*.$suffix 2> /dev/null
done | sort
}
echo "$1"
}
propagateImageName() {
ensureDir $out/nix-support
cat "$diskImage"/nix-support/full-name > $out/nix-support/full-name
}