summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordavidovski <david@davidovski.xyz>2021-12-17 12:13:05 +0000
committerdavidovski <david@davidovski.xyz>2021-12-17 12:13:05 +0000
commit93c7ca3e86dbe088430826d8503da435cbbe4016 (patch)
treebece0f9c9d3e523d461a84dacbe7e4ca1378b45c
parent1077c9387f60f0ef371514cc289075a2720370cc (diff)
added hg
-rwxr-xr-xxibuild5
1 files changed, 5 insertions, 0 deletions
diff --git a/xibuild b/xibuild
index d683e7f..0ec0661 100755
--- a/xibuild
+++ b/xibuild
@@ -90,6 +90,8 @@ xibuild () {
# try get the commit hash for the package
if git ls-remote -q $SOURCE &> /dev/null; then
VER_HASH=$(git ls-remote $SOURCE $BRANCH )
+ elif hg identify $SOURCE &> /dev/null; then
+ VER_HASH=$(hg identify $SOURCE)
else
VER_HASH=$(curl -Ls $SOURCE | md5sum)
fi
@@ -116,6 +118,9 @@ xibuild () {
if git ls-remote -q $SOURCE $BRANCH &> /dev/null; then
git clone $SOURCE . >> $LOGFILE 2>&1 && printf "$PASS fetched $(du -sh $PKG_BUILD_DIR | awk '{ print $1 }') source\n" || return 1;
git checkout $BRANCH >> $LOGFILE 2>&1
+
+ elif hg identify $SOURCE &> /dev/null; then
+ hg clone $SOURCE . >> $LOGFILE 2>&1 && printf "$PASS fetched $(du -sh $PKG_BUILD_DIR | awk '{ print $1 }') source\n" || return 1;
else
DOWNLOADED=$(basename $SOURCE)
curl -Ls $SOURCE > $DOWNLOADED