-
Notifications
You must be signed in to change notification settings - Fork 0
/
gitlab-build.sh
executable file
·27 lines (20 loc) · 1.17 KB
/
gitlab-build.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/bash
set -x -e -o pipefail
export DEBEMAIL='[email protected]'
export DEBFULLNAME='WAND Packaging'
export DEBIAN_FRONTEND=noninteractive
SOURCENAME=`echo ${CI_COMMIT_REF_NAME} | cut -d '-' -f 1`
apt-get update
apt-get install -y equivs devscripts dpkg-dev quilt curl apt-transport-https \
apt-utils ssl-cert ca-certificates gnupg lsb-release debhelper git
echo "deb https://dl.bintray.com/wand/general $(lsb_release -sc) main" | tee -a /etc/apt/sources.list.d/wand.list
echo "deb https://dl.bintray.com/wand/libtrace $(lsb_release -sc) main" | tee -a /etc/apt/sources.list.d/wand.list
echo "deb https://dl.bintray.com/wand/libflowmanager $(lsb_release -sc) main" | tee -a /etc/apt/sources.list.d/wand.list
echo "deb https://dl.bintray.com/wand/libprotoident $(lsb_release -sc) main" | tee -a /etc/apt/sources.list.d/wand.list
curl --silent "https://bintray.com/user/downloadSubjectPublicKey?username=wand"\
| apt-key add -
apt-get update
apt-get upgrade -y
dpkg-parsechangelog -S version | grep -q ${SOURCENAME} || debchange --newversion ${SOURCENAME} -b "New upstream release"
mk-build-deps -i -r -t 'apt-get -f -y --force-yes'
dpkg-buildpackage -b -us -uc -rfakeroot -j4