]> xenbits.xen.org Git - xenclient/build.git/commitdiff
XC-320: Status-report output is empty
authorJean Guyader <jean.guyader@eu.citrix.com>
Tue, 22 Sep 2009 09:44:42 +0000 (10:44 +0100)
committerJean Guyader <jean.guyader@eu.citrix.com>
Tue, 22 Sep 2009 09:44:42 +0000 (10:44 +0100)
Remove the f option to tar.
Rename the function bugtool_file to main_file.

target/generic/target_xenclient_skeleton/usr/bin/status-report

index a5f16c5c10b0b153bae1f38b8894c77535471ab3..c3ff2c402dd37155e461a6f3ab91430b95ad3f7d 100755 (executable)
@@ -37,7 +37,7 @@ archive()
         local out="$1"
         local files="$2"
 
-        tar -cfO $files | bzip2 -z -c > "$out"
+        tar -cO $files | bzip2 -z -c > "$out"
 }
 
 save_file()
@@ -47,7 +47,7 @@ save_file()
         local save_out="$3"
 
         cd "$save_path"
-        archive "${base_path}/${save_out}.tar.bz2" $save_file > ${base_path}/${name}.log 2>&1
+        archive "${base_path}/${save_out}.tar.bz2" $save_path > ${base_path}/${name}.log 2>&1
         files="$files ${save_out}.tar.bz2"
         cd - > /dev/null
 }
@@ -61,12 +61,12 @@ save_out()
         files="$files ${save_out_out}.log"
 }
 
-bugtool_file()
+main_file()
 {
         local base="$1"
 
-        cd "${base_path}"
-        archive "${saved_tarball}" "$files ${name}.log"
+        cd "`dirname "${base_path}"`"
+        archive "${saved_tarball}" "`basename "${base_path}"`"
         cd - > /dev/null
         rm -rf "${base_path}"
 }
@@ -84,7 +84,7 @@ save_out "dmidecode" "dmidecode"
 save_out "xenops list" "xenops_list"
 save_out "brctl show" "brctl_show"
 save_out "ifconfig" "ifconfig"
-bugtool_file "/tmp/$name/$name-$d"
+main_file "/tmp/$name/$name-$d"
 sync
 
 echo "Writing tarball ${saved_tarball} successful."