Skip to content

Commit 12bbf48

Browse files
committed
Add SKIP_UPLOAD var
1 parent 5a069d9 commit 12bbf48

1 file changed

Lines changed: 14 additions & 7 deletions

File tree

‎build.sh‎

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,10 +41,17 @@ echo "This is Proxmox-Port package build scripts"
4141
echo "Package is $PKGNAME"
4242
echo "Docker build is $BUILDERNAME"
4343
echo "Package dir is $PKG_LOCATION_PATH/$PKGNAME"
44+
4445
if [ -n "$DEB_BUILD_OPTIONS" ];
4546
then
4647
echo "DEB_BUILD_OPTIONS = $DEB_BUILD_OPTIONS"
4748
fi
49+
50+
if [ -n "$SKIP_UPLOAD" ];
51+
then
52+
echo "SKIP_UPLOAD is set!"
53+
fi
54+
4855
echo "--------------start-----------------"
4956

5057
dockerbuild(){
@@ -59,12 +66,10 @@ dockerbuild(){
5966
upload_pkg(){
6067
rm $PKG_LOCATION_PATH/$PKGNAME -rf
6168
mkdir $PKG_LOCATION_PATH/$PKGNAME -p
62-
find "$SH_PATH/packages/$PKGNAME/$PKGNAME" -name "*.deb" -exec cp {} $PKG_LOCATION_PATH/$PKGNAME \;
63-
find "$SH_PATH/packages/$PKGNAME/$PKGNAME" -name "*.buildinfo" -exec cp {} $PKG_LOCATION_PATH/$PKGNAME \;
64-
find "$SH_PATH/packages/$PKGNAME/$PKGNAME" -name "*.changes" -exec cp {} $PKG_LOCATION_PATH/$PKGNAME \;
65-
find "$SH_PATH/packages/$PKGNAME/$PKGNAME" -name "*.dsc" -exec cp {} $PKG_LOCATION_PATH/$PKGNAME \;
66-
find "$SH_PATH/packages/$PKGNAME/$PKGNAME" -name "*.tar*" -exec cp {} $PKG_LOCATION_PATH/$PKGNAME \;
67-
ls $PKG_LOCATION_PATH/$PKGNAME/
69+
70+
cd $SH_PATH/packages/$PKGNAME/$PKGNAME
71+
cp *.deb *.buildinfo *.changes *.dsc *.tar* $PKG_LOCATION_PATH/$PKGNAME ||true
72+
6873
for i in `ls $PKG_LOCATION_PATH/$PKGNAME/*.deb`;
6974
do
7075
md5sum $i > $i.md5
@@ -124,5 +129,7 @@ fi
124129
cd $SH_PATH
125130

126131
dockerbuild
127-
upload_pkg || errlog "upload pkg failed"
128132

133+
if [ ! -n $SKIP_UPLOAD ];then
134+
upload_pkg || errlog "upload pkg failed"
135+
fi

0 commit comments

Comments
 (0)