]> code.ossystems Code Review - openembedded-core.git/commitdiff
bitbake-prserv-tool: show error when export file does not exist
authorMartin Jansa <martin.jansa@gmail.com>
Wed, 6 Feb 2013 14:23:38 +0000 (15:23 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 6 Feb 2013 16:50:54 +0000 (16:50 +0000)
* otherwise it shows error about failing import

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
scripts/bitbake-prserv-tool

index 4654e6d42127b186eff1355c133f62e689f70d43..96a34702c93400378dada4f273d3a2ab5678a13b 100755 (executable)
@@ -61,8 +61,16 @@ do_migrate_localcount ()
     clean_cache
     echo "Exporting LOCALCOUNT to AUTOINCs..."
     bitbake -R conf/migrate_localcount.conf -p
-    [ ! $? -eq 0 ] && echo "Exporting failed!" && exit 1
+    [ ! $? -eq 0 ] && echo "Exporting to file $df failed!" && exit 1
 
+    if [ -e $df ];
+    then
+        echo "Exporting to file $df succeeded!"
+    else
+        echo "Exporting to file $df failed!"
+        exit 1
+    fi
+    
     echo "Importing generated AUTOINC entries..."
     [ -e $df ] && do_import $df