fixup zmrepo options for releases and master
This commit is contained in:
parent
ad166ab49a
commit
7b5e9968ad
|
@ -127,11 +127,7 @@ else
|
||||||
fi;
|
fi;
|
||||||
|
|
||||||
cd "${GITHUB_FORK}_zoneminder_release"
|
cd "${GITHUB_FORK}_zoneminder_release"
|
||||||
if [ $RELEASE ]; then
|
|
||||||
git checkout $RELEASE
|
|
||||||
else
|
|
||||||
git checkout $BRANCH
|
git checkout $BRANCH
|
||||||
fi;
|
|
||||||
cd ../
|
cd ../
|
||||||
|
|
||||||
VERSION=`cat ${GITHUB_FORK}_zoneminder_release/version`
|
VERSION=`cat ${GITHUB_FORK}_zoneminder_release/version`
|
||||||
|
@ -146,6 +142,11 @@ fi;
|
||||||
DIRECTORY="zoneminder_$VERSION";
|
DIRECTORY="zoneminder_$VERSION";
|
||||||
echo "Doing $TYPE release $DIRECTORY";
|
echo "Doing $TYPE release $DIRECTORY";
|
||||||
mv "${GITHUB_FORK}_zoneminder_release" "$DIRECTORY.orig";
|
mv "${GITHUB_FORK}_zoneminder_release" "$DIRECTORY.orig";
|
||||||
|
if [ $? -ne 0 ]; then
|
||||||
|
echo "Error status code is: $?"
|
||||||
|
echo "Setting up build dir failed.";
|
||||||
|
exit $?;
|
||||||
|
fi;
|
||||||
cd "$DIRECTORY.orig";
|
cd "$DIRECTORY.orig";
|
||||||
|
|
||||||
git submodule init
|
git submodule init
|
||||||
|
@ -214,6 +215,7 @@ else
|
||||||
echo "Status: $?"
|
echo "Status: $?"
|
||||||
DEBUILD="debuild -i -us -uc -b"
|
DEBUILD="debuild -i -us -uc -b"
|
||||||
else
|
else
|
||||||
|
# Source build, don't need build depends.
|
||||||
DEBUILD="debuild -S -sa"
|
DEBUILD="debuild -S -sa"
|
||||||
fi;
|
fi;
|
||||||
fi;
|
fi;
|
||||||
|
@ -230,10 +232,10 @@ fi;
|
||||||
cd ../
|
cd ../
|
||||||
if [ "$INTERACTIVE" != "no" ]; then
|
if [ "$INTERACTIVE" != "no" ]; then
|
||||||
read -p "Do you want to keep the checked out version of Zoneminder (incase you want to modify it later) [y/N]"
|
read -p "Do you want to keep the checked out version of Zoneminder (incase you want to modify it later) [y/N]"
|
||||||
[[ $REPLY == [yY] ]] && { mv $DIRECTORY zoneminder_release; echo "The checked out copy is preserved in zoneminder_release"; } || { rm -fr $DIRECTORY; echo "The checked out copy has been deleted"; }
|
[[ $REPLY == [yY] ]] && { mv "$DIRECTORY.orig" zoneminder_release; echo "The checked out copy is preserved in zoneminder_release"; } || { rm -fr "$DIRECTORY.orig"; echo "The checked out copy has been deleted"; }
|
||||||
echo "Done!"
|
echo "Done!"
|
||||||
else
|
else
|
||||||
rm -fr $DIRECTORY; echo "The checked out copy has been deleted";
|
rm -fr "$DIRECTORY.orig"; echo "The checked out copy has been deleted";
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ $TYPE == "binary" ]; then
|
if [ $TYPE == "binary" ]; then
|
||||||
|
@ -244,11 +246,19 @@ if [ $TYPE == "binary" ]; then
|
||||||
sudo dpkg -i $DIRECTORY*.deb
|
sudo dpkg -i $DIRECTORY*.deb
|
||||||
fi;
|
fi;
|
||||||
if [ "$DISTRO" == "jessie" ]; then
|
if [ "$DISTRO" == "jessie" ]; then
|
||||||
echo "Do you want to upload this binary to zmrepo? (y/N)"
|
echo "Do you want to upload this binary to zmrepo? (y/N)"
|
||||||
read install
|
read install
|
||||||
if [ "$install" == "Y" ]; then
|
if [ "$install" == "Y" ]; then
|
||||||
scp "zoneminder_*-${VERSION}-${DISTRO}*" "zmrepo@zmrepo.connortechnology.com:debian/${BRANCH}/mini-dinstall/incoming/"
|
if [ "$RELEASE" != "" ]; then
|
||||||
|
scp "zoneminder_${VERSION}-${DISTRO}*" "zmrepo@zmrepo.connortechnology.com:debian/stable/mini-dinstall/incoming/"
|
||||||
|
else
|
||||||
|
if [ "$BRANCH" == "" ]; then
|
||||||
|
scp "zoneminder_${VERSION}-${DISTRO}*" "zmrepo@zmrepo.connortechnology.com:debian/master/mini-dinstall/incoming/"
|
||||||
|
else
|
||||||
|
scp "zoneminder_${VERSION}-${DISTRO}*" "zmrepo@zmrepo.connortechnology.com:debian/${BRANCH}/mini-dinstall/incoming/"
|
||||||
|
fi;
|
||||||
fi;
|
fi;
|
||||||
|
fi;
|
||||||
fi;
|
fi;
|
||||||
fi;
|
fi;
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue