~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to tools/packaging/update-changelogs.sh

  • Committer: Tarmac
  • Author(s): Vincent Ladeuil
  • Date: 2017-01-30 14:42:05 UTC
  • mfrom: (6620.1.1 trunk)
  • Revision ID: tarmac-20170130144205-r8fh2xpmiuxyozpv
Merge  2.7 into trunk including fix for bug #1657238 [r=vila]

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#!/bin/bash
 
2
# Helper to insert a new entry in debian/changelog
2
3
 
3
4
if [ -z "$UBUNTU_RELEASES" ]; then
4
5
    echo "Configure the distro platforms that you want to"
7
8
    exit 1
8
9
fi
9
10
 
10
 
if [ "x$1" = "x" ]; then
 
11
if [ "x$VERSION" = "x" ]; then
11
12
    echo "Missing version"
12
13
    echo "You want something like:"
13
 
    echo "  update-changelogs.sh 1.6~rc1-1~bazaar1"
 
14
    echo "  VERSION=1.6~rc1-1~bazaar1 update-changelogs.sh"
14
15
    echo "or"
15
 
    echo "  update-changelogs.sh 1.6-1~bazaar1"
 
16
    echo "  VERSION=1.6-1~bazaar1 update-changelogs.sh"
16
17
    exit
17
18
fi
18
 
VERSION=$1
 
19
 
 
20
if [ -z "$1" ]; then
 
21
    MSG="New upstream release"
 
22
else
 
23
    MSG=$1
 
24
fi
19
25
 
20
26
for DISTRO in $UBUNTU_RELEASES; do
21
27
    PPAVERSION="$VERSION~${DISTRO}1"
22
28
    (
23
29
        echo "Updating changelog for $DISTRO"
24
 
        cd "packaging-$DISTRO" &&
25
 
        dch -v $PPAVERSION -D $DISTRO -c changelog 'New upstream release.' &&
26
 
        bzr commit -m "New upstream release: $PPAVERSION"
 
30
        cd "$PACKAGE-$DISTRO" &&
 
31
            dch -v $PPAVERSION -D $DISTRO "$MSG." &&
 
32
            bzr commit -m "$MSG: $PPAVERSION"
27
33
    )
28
34
done