build: replace custom release script with release-please (#2817)

* build: replace custom release script with release-please

* include package-name
This commit is contained in:
Jonas L 2023-12-22 19:19:12 +01:00 committed by GitHub
parent 3e06cc1072
commit e7a678e91f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 102 additions and 203 deletions

View file

@ -1,21 +0,0 @@
#!/usr/bin/env bash
# Bump the version in the setup.py files.
set -u
error() {
echo >&2 "error: $*"
exit 1
}
command -v sed > /dev/null || error "sed command not found!"
version="$1"
for setup_path in */setup.py; do
sed --in-place \
"s/version=\".*\",/version=\"$version\",/" \
"$setup_path" ||
error "could not bump version for $setup_path!"
done

View file

@ -1,25 +0,0 @@
#!/usr/bin/env bash
set -u
error() {
echo >&2 "error: $*"
exit 1
}
command -v git > /dev/null || error "git command not found!"
command -v git-chglog > /dev/null || error "git-chglog command not found!"
changelog="CHANGELOG.md"
tag="${tag:-$(git describe --abbrev=0 --tags || error "could not extract latest tag")}"
if grep --quiet "<a name=\"$tag\"></a>" "$changelog"; then
error "changelog has already been generated for tag $tag!"
fi
cat <(git-chglog "$tag") "$changelog" > "$changelog.tmp"
mv "$changelog.tmp" "$changelog"
if command -v npx > /dev/null; then
npx prettier --write "$changelog"
fi