notcurses/tools/release.sh

34 lines
918 B
Bash
Raw Normal View History

2020-04-19 06:23:08 +00:00
#!/bin/sh
set -e
usage() { echo "usage: `basename $0` oldversion newversion" ; }
[ $# -eq 2 ] || { usage >&2 ; exit 1 ; }
OLDVERSION="$1"
VERSION="$2"
2020-05-11 01:38:46 +00:00
vi NEWS.md
2020-04-19 06:23:08 +00:00
git clean -f -d -x
2020-05-17 11:29:10 +00:00
BUMP="CMakeLists.txt doc/Doxyfile doc/man/man*/* doc/man/index.html python/setup.py rust/*/Cargo.toml rust/libnotcurses-sys/build.rs"
2020-04-19 06:23:08 +00:00
for i in $BUMP ; do
sed -i -e "s/$OLDVERSION/$VERSION/g" $i
done
echo "Checking for instances of $OLDVERSION..."
2020-05-17 13:01:53 +00:00
grep -rF "$OLDVERSION" * || true
2020-04-19 06:23:08 +00:00
git commit -a -m v$VERSION
git push
git pull
2020-05-17 12:12:26 +00:00
git tag -a v$VERSION -m v$VERSION -s
2020-04-19 06:23:08 +00:00
git push origin --tags
git pull
wget https://github.com/dankamongmen/notcurses/archive/v$VERSION.tar.gz
gpg --sign --armor --detach-sign v$VERSION.tar.gz
rm v$VERSION.tar.gz
2020-04-19 06:23:08 +00:00
echo "Cut $VERSION, signed to v$VERSION.tar.gz.asc"
echo "Now upload the sig to https://github.com/dankamongmen/notcurses/releases"
echo "The bastards are trying to immanentize the Eschaton"