Migrated release script to use Buck exclusively.

Change-Id: I04371594b68071488788c4ecbdb896a6306a2a14
diff --git a/tools/build/onos-upload-bits b/tools/build/onos-upload-bits
index e3bb83c..c9f4c80 100755
--- a/tools/build/onos-upload-bits
+++ b/tools/build/onos-upload-bits
@@ -9,6 +9,20 @@
 . $ONOS_ROOT/tools/build/envDefaults
 
 #FIXME need to export s3Creds
-#TODO we could verify that ONOS_VERSION is set, and only upload that version
 
-onosUploadBits.py
+# Stage the onos tar in /tmp
+rm -f $ONOS_TAR
+cp $(onos-buck build onos --show-output | tail -1 | cut -d\  -f2) $ONOS_TAR
+
+# Repackage the onos tar
+pushd /tmp/
+tar xf onos-$ONOS_VERSION.tar.gz
+rm -f onos-$ONOS_VERSION.zip
+zip -r onos-$ONOS_VERSION.zip onos-$ONOS_VERSION/
+popd
+
+# Stage the test bits tar in /tmp
+rm -f $ONOS_TEST_TAR
+cp $(onos-buck build //:onos-test --show-output | tail -1 | cut -d\  -f2) $ONOS_TEST_TAR
+
+onosUploadBits.py $ONOS_VERSION