summaryrefslogtreecommitdiff
path: root/bin/signtarballs
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2017-06-23 15:59:09 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2017-06-23 15:59:09 +0200
commit66508985dd6049445d7a340c2dc22e7fa41cd367 (patch)
tree4bcc8bd19e76bb87be6bfb0f7a04ecd92ffcad4e /bin/signtarballs
parentb6a9742a2a4501f025ec04eb058ad06393f1ec98 (diff)
downloadbuildscripts-66508985dd6049445d7a340c2dc22e7fa41cd367.tar.gz
buildscripts-66508985dd6049445d7a340c2dc22e7fa41cd367.tar.bz2
buildscripts-66508985dd6049445d7a340c2dc22e7fa41cd367.zip
signtarballs: Be more intelligent when scanning for the location of the _releases_ directory.
Diffstat (limited to 'bin/signtarballs')
-rwxr-xr-xbin/signtarballs4
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/signtarballs b/bin/signtarballs
index e7f50ce..9438607 100755
--- a/bin/signtarballs
+++ b/bin/signtarballs
@@ -1,8 +1,8 @@
#!/bin/bash
-test -d _releases_ && cd _releases_ || test -d ../_releases_ && cd ../_releases_ || exit 1
+d=. ; while [ ! -d $d/_releases_ -a `readlink -e $d` != / ]; do d=$d/..; done
-find * -type f | egrep ".*(\.zip|\.tar\.gz|\.exe|\.dmg)$" | while read tarball; do
+find $d/_releases_ -type f | egrep ".*(\.zip|\.tar\.gz|\.exe|\.dmg)$" | while read tarball; do
test -f "${tarball}.md5" || { printf "md5: "; md5sum "${tarball}" | tee "${tarball}.md5"; }
test -f "${tarball}.sha1" || { printf "sha1: "; sha1sum "${tarball}" | tee "${tarball}.sha1"; }
test -f "${tarball}.sha256" || { printf "sha256: "; sha256sum "${tarball}" | tee "${tarball}.sha256"; }