Add workaround to unzip not fully extracting all contents 08/51808/5
authorJamo Luhrsen <jluhrsen@redhat.com>
Mon, 13 Feb 2017 18:24:57 +0000 (10:24 -0800)
committerJamo Luhrsen <jluhrsen@redhat.com>
Tue, 14 Feb 2017 18:23:18 +0000 (10:23 -0800)
Change-Id: I06b02254928b431293c2174efa4fe1224904b4da
Signed-off-by: Jamo Luhrsen <jluhrsen@redhat.com>
jjb/integration/include-raw-integration-compare-distributions.sh

index 05a8e1acf4adba6a73dbdd42731d10fac6674bd6..8e54b8370c5627fc1137b585ddcd4ec02bacf596 100644 (file)
@@ -15,8 +15,8 @@ NEW_DISTRO=$(find $WORKSPACE -name distribution-karaf*.zip)
 NEW_DISTRO_BASENAME=$(basename $NEW_DISTRO)
 cp $NEW_DISTRO /tmp/
 cd /tmp/
-# the following extracts the .zip and learns the name of the folder extracted to
-EXTRACTED_FOLDER=$(unzip $NEW_DISTRO_BASENAME | grep -m1 'creating:' | cut -d' ' -f5-)
+# get the name of the folder which will be extracted to
+EXTRACTED_FOLDER=$(unzip $NEW_DISTRO_BASENAME | grep 'creating:' | grep -v '/.' | cut -d' ' -f5-)
 mv $EXTRACTED_FOLDER distro_new
 
 git clone https://git.opendaylight.org/gerrit/p/integration/test.git