incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bdelacre...@apache.org
Subject svn commit: r997835 - /sling/trunk/check_staged_release.sh
Date Thu, 16 Sep 2010 16:45:32 GMT
Author: bdelacretaz
Date: Thu Sep 16 16:45:32 2010
New Revision: 997835

URL: http://svn.apache.org/viewvc?rev=997835&view=rev
Log:
SLING-1780 - correctly handle missing .md5 / .sha1 files

Modified:
    sling/trunk/check_staged_release.sh

Modified: sling/trunk/check_staged_release.sh
URL: http://svn.apache.org/viewvc/sling/trunk/check_staged_release.sh?rev=997835&r1=997834&r2=997835&view=diff
==============================================================================
--- sling/trunk/check_staged_release.sh (original)
+++ sling/trunk/check_staged_release.sh Thu Sep 16 16:45:32 2010
@@ -48,9 +48,14 @@ do
 
  for tp in md5 sha1
  do
-   A="`cat $f.$tp 2>/dev/null`"
-   B="`openssl $tp < $f 2>/dev/null | sed 's/.*= *//' `"
-   if [ "$A" = "$B" ]; then CHKSUM="GOOD (`cat $f.$tp`)"; else CHKSUM="BAD!! : $A not equal
to $B"; fi
+   if [ ! -f "$f.$tp" ]
+   then
+     CHKSUM="----"
+   else
+     A="`cat $f.$tp 2>/dev/null`"
+     B="`openssl $tp < $f 2>/dev/null | sed 's/.*= *//' `"
+     if [ "$A" = "$B" ]; then CHKSUM="GOOD (`cat $f.$tp`)"; else CHKSUM="BAD!! : $A not equal
to $B"; fi
+   fi
    echo "$tp : ${CHKSUM}"
  done
 



Mime
View raw message