Skip to content

Commit

Permalink
rewrite tools/debrelease.sh using gh #2830
Browse files Browse the repository at this point in the history
  • Loading branch information
dankamongmen committed Jan 9, 2025
1 parent e0461a8 commit 7618f61
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
2 changes: 1 addition & 1 deletion doc/release-checklist.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@

### Debian

* In gbp repository, run `tools/debrelease.sh $VERSION`:
* In gbp repository, run `tools/debrelease.sh $VERSION path-to-notcurses-checkout`:
* Updates Debian changelog with `dch -v $VERSION+dfsg.1-1`
* Finalizes Debian changelog with `dch -r`
* Repacks DFSG-safe tarball with `uscan`:
Expand Down
14 changes: 9 additions & 5 deletions tools/debrelease.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,12 @@ set -e
# export DISTRIBUTION to use something other than unstable (or whatever was
# last used in debian/changelog). see dch(1). can use a DEBVERSION exported
# in the process's environment.
usage() { echo "usage: `basename $0` version" ; }
usage() { echo "usage: `basename $0` version notcursessrcdir" ; }

[ $# -eq 1 ] || { usage >&2 ; exit 1 ; }
[ $# -eq 2 ] || { usage >&2 ; exit 1 ; }

VERSION="$1"
SRCDIR="$2"

if [ -z "$DEBVERSION" ] ; then
DEBVERSION=1
Expand All @@ -23,9 +24,12 @@ else
dch -r
fi
uscan --repack --compression xz --force
gpg --sign --armor --detach-sign ../notcurses_$VERSION+dfsg.1.orig.tar.xz
# FIXME this seems to upload to $VERSION.dfsg as opposed to $VERSION+dfsg?
github-asset dankamongmen/notcurses upload v$VERSION ../notcurses_$VERSION+dfsg.1.orig.tar.xz ../notcurses_$VERSION+dfsg.1.orig.tar.xz.asc
XBALL=notcurses_$VERSION+dfsg.1.orig.tar.xz
gpg --sign --armor --detach-sign ../$XBALL
ASC=$(readlink -f ../$XBALL.asc)
cd "$SRCDIR"
gh release upload v$VERSION $ASC $(readlink -f $XBALL)
cd -
git commit -m "v$VERSION" -a

echo
Expand Down

0 comments on commit 7618f61

Please sign in to comment.