summaryrefslogtreecommitdiffstats
path: root/controller/libexec/dtf-commit-results.in
diff options
context:
space:
mode:
Diffstat (limited to 'controller/libexec/dtf-commit-results.in')
-rw-r--r--controller/libexec/dtf-commit-results.in10
1 files changed, 7 insertions, 3 deletions
diff --git a/controller/libexec/dtf-commit-results.in b/controller/libexec/dtf-commit-results.in
index b1d5bf2..d7a6949 100644
--- a/controller/libexec/dtf-commit-results.in
+++ b/controller/libexec/dtf-commit-results.in
@@ -12,13 +12,17 @@ db="$DTF_DATABASE_DEFAULT"
test -n "$3" && db="$3"
if test -z "$db" \
- || test -z "$resultdir" \
- || test ! -f "$resultdir/dtf.tar.gz"
+ || test -z "$resultdir"
then
echo >&2 "something is wrong, try bash -x"
exit 1
fi
+if test -f "$resultdir/dtf.tar.gz"; then
+ # Unpack tarball if available..
+ ( cd "$resultdir" && tar -xf dtf.tar.gz )
+fi
+
mkdir -p "$db/$subresultdir" || exit 1
-( cd "$resultdir" && tar -xf dtf.tar.gz && cp -r . "$db/$subresultdir" )
+( cd "$resultdir" && cp -r . "$db/$subresultdir" )