Clean up temporary files on exit

Change-Id: I3568c76529fe3f66a5d8b8e5bdaa365f56c589a8
This commit is contained in:
Yuta HIGUCHI 2017-01-12 09:57:32 -08:00 committed by Thomas Vachuska
parent c2093cbb33
commit aa0cb506bf
2 changed files with 4 additions and 0 deletions

View File

@ -14,6 +14,8 @@ TEST_PUB=$(mktemp /tmp/onos-publish-tests.XXXXX) &&
echo "Created temp file for test artifact publish: $TEST_PUB" ||
{ echo "Failed to create temp file"; exit 1; }
trap "rm -f $ARTIFACT_PUB $ARTIFACT_PUB.bak $TEST_PUB $TEST_PUB.bak" EXIT
set -e
set -x

View File

@ -4,6 +4,8 @@ set -e
onos-buck -V
rm -f /tmp/publish.sh
trap "rm -f /tmp/publish.sh /tmp/publish.sh.bak" EXIT
onos-buck query "kind('onos_jar', deps('//tools/package:onos-package'))" >> /tmp/publish.sh