Skip image creation if No KS files generated or found
authorZhang Qiang <qiang.z.zhang@intel.com>
Wed, 5 Mar 2014 06:03:37 +0000 (14:03 +0800)
committerJunchun Guan <junchunx.guan@intel.com>
Thu, 6 Mar 2014 07:12:47 +0000 (15:12 +0800)
Change-Id: Ice3d6bd4b988c8153cd5f797ef7760ab99da90f2

jenkins-jobs/scripts/common_functions

index a68a72143eddad26c83a21ba117c77da9ed0dd7f..2f5d29c27b5bb2f467be7905a21fa80762acdf88 100755 (executable)
@@ -73,6 +73,11 @@ function update_ks_file(){
 #Create images
 function create_images()
 {
+    if [ -z "$KS_FILES" ]; then
+        echo "No KS files found, skip image creation "
+        return
+    fi
+
     update_ks_file
 
     for ks in $KS_FILES