blob: 35013a5a73d54b0b08f5c83f9f6dc1b0810448fa (
plain) (
blame)
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
28
29
30
31
32
33
34
|
#!/bin/sh
if [ "$#" -ne 3 ];then
cat >&2 <<EOF
${0##*/} [operation] [distribution] [arch]
operation: create | update | build
EOF
exit
fi
if [ "$1" = "build" ]
then
set -x
exec \
gbp buildpackage \
--git-pbuilder \
--git-dist="$2" \
--git-arch="$3" \
--git-pbuilder-options="--mirror https://deb.debian.org/debian"
fi
sudo -i <<EOF
set -e
pbuilder "$1" \\
--distribution "$2" \\
--mirror https://deb.debian.org/debian \\
--architecture "$3" \\
--basetgz "/var/cache/pbuilder/base-$2-$3.tgz"
cowbuilder "$1" \\
--distribution "$2" \\
--mirror https://deb.debian.org/debian \\
--architecture "$3" \\
--basepath "/var/cache/pbuilder/base-$2-$3.cow"
EOF
|