Merge "In order for xrefs to work, use the git commit id and not the superproject sha" into androidx-main
diff --git a/busytown/impl/merge-kzips.sh b/busytown/impl/merge-kzips.sh
index 6178d47..100f04f 100755
--- a/busytown/impl/merge-kzips.sh
+++ b/busytown/impl/merge-kzips.sh
@@ -39,13 +39,10 @@
mkdir -p "$DIST_DIR"
export DIST_DIR="$DIST_DIR"
+# Default KZIP_NAME to the latest Git commit hash
+: ${KZIP_NAME:=$(git rev-parse HEAD)}
-# If the SUPERPROJECT_REVISION is defined as a sha, use this as the default value
-if [[ ${SUPERPROJECT_REVISION:-} =~ [0-9a-f]{40} ]]; then
- : ${KZIP_NAME:=${SUPERPROJECT_REVISION:-}}
-fi
-
-: ${KZIP_NAME:=${BUILD_NUMBER:-}}
+# Fallback to a UUID if Git commit hash is not there
: ${KZIP_NAME:=$(uuidgen)}
@@ -61,4 +58,3 @@
fi
"$BUILD_TOOLS_DIR/merge_zips" "$DIST_DIR/$allkzip" @<(find "$OUT_DIR/androidx" -name '*.kzip')
-