8000 Update release-script to work with any branch · v4l2loopback/v4l2loopback@8678012 · GitHub
[go: up one dir, main page]

Skip to content

Commit 8678012

Browse files
committed
Update release-script to work with any branch
1 parent 1ecf810 commit 8678012

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

release.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
CHANGELOG=ChangeLog
1414
AUTHORS=AUTHORS
1515
NEWS=NEWS
16+
: ${mainbranch:=release}
1617

1718
error() {
1819
echo "$@" 1>&2
@@ -38,8 +39,8 @@ getgitbranch() {
3839
git rev-parse --abbrev-ref HEAD
3940
}
4041

41-
if [ "$(getgitbranch)" != "master" ]; then
42-
fatal "current branch '$(getgitbranch)' is not 'master'"
42+
if [ "$(getgitbranch)" != "${mainbranch}" ]; then
43+
fatal "current branch '$(getgitbranch)' is not '${mainbranch}'"
4344
fi
4445

4546
if [ "x$2" = "x" ]; then
@@ -82,7 +83,7 @@ echo "updating to ${NEWVERSION}"
8283
OK=false
8384
mkdir debian
8485
cp ${CHANGELOG} debian/changelog
85-
gbp dch -R --since "v${OLDVERSION}" -N "${NEWVERSION}" && cat debian/changelog > ${CHANGELOG} && OK=true
86+
gbp dch -R --since "v${OLDVERSION}" -N "${NEWVERSION}" --debian-branch="${mainbranch}" && cat debian/changelog > ${CHANGELOG} && OK=true
8687
rm -rf debian
8788

8889
if [ "x${OK}" = "xtrue" ]; then

0 commit comments

Comments
 (0)
0