]> https://gitweb.dealii.org/ - candi.git/commitdiff
candi: Bugfix if CHECKSUM=ignore
authorUwe Köcher <koecher@hsu-hamburg.de>
Thu, 5 Nov 2015 17:38:17 +0000 (18:38 +0100)
committerUwe Köcher <koecher@hsu-hamburg.de>
Thu, 5 Nov 2015 17:38:17 +0000 (18:38 +0100)
candi.sh

index 2fa68eabb15de54c4f17045f417fc798b4cfded8..d8fdee8f1c4202a4b936dd91f1c9ca335005ff77 100755 (executable)
--- a/candi.sh
+++ b/candi.sh
@@ -128,6 +128,11 @@ quit_if_fail() {
 verify_archive() {
     ARCHIVE_FILE=$1
     
+    # Make sure the archive was downloaded
+    if [ ! -e ${ARCHIVE_FILE} ]; then
+        return 2
+    fi
+    
     # Check checksum has been specified for the package
     if [ -z "${CHECKSUM}" ]; then
         cecho ${WARN} "No checksum for ${ARCHIVE_FILE}"
@@ -140,11 +145,6 @@ verify_archive() {
         return 1
     fi
     
-    # Make sure the archive was downloaded
-    if [ ! -e ${ARCHIVE_FILE} ]; then
-        return 2
-    fi
-    
     cecho ${INFO} "Verifying ${ARCHIVE_FILE}"
     
     # Verify checksum using md5/md5sum

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.