1 | 1 |
|
2 | 2 |
. ./vars.sh.frag
|
3 | 3 |
|
4 | |
git diff -q -- "$PKGDIR_REL" || \
|
|
4 |
git diff --quiet --cached || \
|
|
5 |
abort 1 "You have other pending changes to git, please complete it or stash it away and re-run this script."
|
|
6 |
|
|
7 |
git diff --quiet -- "$PKGDIR_REL" || \
|
5 | 8 |
abort 1 "Please git-add your changes to $PKGDIR_REL before running"
|
|
9 |
|
|
10 |
head -n1 "$PKGDIR/debian/changelog" | grep -q UNRELEASED-FIXME-AUTOGENERATED-DEBCARGO || \
|
|
11 |
abort 1 "Package already released. If that was a mistake and you didn't actually upload yet, you may rewind your git and re-run this script."
|
6 | 12 |
|
7 | 13 |
( cd "$PKGDIR"
|
8 | 14 |
sed -i -e s/UNRELEASED-FIXME-AUTOGENERATED-DEBCARGO/UNRELEASED/ debian/changelog
|
|
19 | 25 |
git commit -m "Release package $PKG"
|
20 | 26 |
|
21 | 27 |
( cd "$BUILDDIR" && dpkg-buildpackage -d -S --no-sign )
|
|
28 |
|
|
29 |
cat >&2 <<eof
|
|
30 |
Release of $PKG ready as a source package in ${BUILDDIR#$PWD/}.
|
|
31 |
|
|
32 |
If the source package is already in Debian and this version does not introduce
|
|
33 |
new binaries, then you can just go ahead and directly dput the source package.
|
|
34 |
|
|
35 |
If this is a NEW source package or introduces NEW binary packages not already
|
|
36 |
in the Debian archive, you will need to build a binary package out of it. The
|
|
37 |
recommended way is to run something like:
|
|
38 |
|
|
39 |
$ sbuild <source_package.dsc>
|
|
40 |
$ changestool <sbuild_binary_changes.changes> addsc <source_package.dsc>
|
|
41 |
$ debsign --no-re-sign <sbuild_binary_changes.changes>
|
|
42 |
$ dput <sbuild_binary_changes.changes>
|
|
43 |
|
|
44 |
See https://wiki.debian.org/sbuild for instructions on how to set it up. The
|
|
45 |
other tools are from the 'devscripts' package.
|
|
46 |
|
|
47 |
The above assumes you are a Debian Developer. If not, you should revert your
|
|
48 |
changes and ask a Debian Developer to do this step.
|
|
49 |
eof
|