|
@@ -1,13 +1,24 @@
|
|
|
#!/bin/bash
|
|
|
+ERROR=0
|
|
|
GIT_REPO=https://gitlab.com/frg/seamonkey-central-patches.git
|
|
|
rm -rf /tmp/comm-xul$$ /tmp/git-xul$$
|
|
|
pushd /tmp
|
|
|
-hg clone https://hg.mozilla.org/comm-central/ /tmp/comm-xul$$ || exit 1
|
|
|
+hg clone https://hg.mozilla.org/comm-central/ /tmp/comm-xul$$ || ERROR=1
|
|
|
+if [ $ERROR -eq 1 ]
|
|
|
+then
|
|
|
+ rm -rf /tmp/*$$
|
|
|
+ exit 1
|
|
|
+fi
|
|
|
if [ '$GIT_REPO' != '' ]
|
|
|
then
|
|
|
mkdir /tmp/git-xul$$
|
|
|
cd /tmp/git-xul$$
|
|
|
- git clone $GIT_REPO || exit 1
|
|
|
+ git clone $GIT_REPO || ERROR=1
|
|
|
+ if [ $ERROR -eq 1 ]
|
|
|
+ then
|
|
|
+ rm -rf /tmp/*$$
|
|
|
+ exit 1
|
|
|
+ fi
|
|
|
cd /tmp/comm-xul$$
|
|
|
if [ -s /tmp/git-xul$$/seamonkey-central-patches/comm-central/patches/series ]
|
|
|
then
|
|
@@ -17,7 +28,12 @@ then
|
|
|
then
|
|
|
break
|
|
|
fi
|
|
|
- hg import /tmp/git-xul$$/seamonkey-central-patches/comm-central/patches/$i || exit 1
|
|
|
+ hg import /tmp/git-xul$$/seamonkey-central-patches/comm-central/patches/$i || ERROR=1
|
|
|
+ if [ $ERROR -eq 1 ]
|
|
|
+ then
|
|
|
+ rm -rf /tmp/*$$
|
|
|
+ exit 1
|
|
|
+ fi
|
|
|
done
|
|
|
fi
|
|
|
fi
|