GIT: Switches to shallow clones

Goes from full git clones to a shallow clone (depth = 1) to reduce space
usage.

Change-Id: Ibdbd03ec319deb22ec21d971e1ce5ba7e678ec1c
Signed-off-by: Matthew Dalzell <matthew.dalzell@arm.com>
diff --git a/clone.sh b/clone.sh
index 2ee3308..7060091 100755
--- a/clone.sh
+++ b/clone.sh
@@ -53,9 +53,8 @@
     fi
 
     if [ ! -f "${SHARE_FOLDER}/${REPO_NAME}.tar.gz" ]; then
-        git_clone $REPO_URL "${SHARE_FOLDER}/${REPO_NAME}"
+        git_clone $REPO_URL "${SHARE_FOLDER}/${REPO_NAME}" ${REPO_REFSPEC} ${SYNC_CMD}
         # Compress for shared area
-        git_checkout "${SHARE_FOLDER}/${REPO_NAME}" $REPO_REFSPEC $SYNC_CMD
         cd ${SHARE_FOLDER}
         if [ "${REPO_NAME}" = "${TFM_NAME}" ] || [ "${REPO_NAME}" = "${TFM_TESTS_NAME}" ]; then
             # These two need to remain as directories for now for further usage