Skip to content
Snippets Groups Projects
Commit 01dbc22c authored by Martin Pitt's avatar Martin Pitt Committed by Martin Pitt
Browse files

Change releases to put news in tags

Stop using the NEWS file and put release news into the tag description.
Use https://github.com/marketplace/actions/github-release-from-tag to
publish the GitHub release.
parent 12ea2e33
Branches
Tags
No related merge requests found
assets:
- path: umockdev-*.tar.xz
...@@ -10,6 +10,9 @@ jobs: ...@@ -10,6 +10,9 @@ jobs:
steps: steps:
- name: Clone repository - name: Clone repository
uses: actions/checkout@v2 uses: actions/checkout@v2
with:
# need this to also fetch tags
fetch-depth: 0
- name: Workaround for https://github.com/actions/checkout/pull/697 - name: Workaround for https://github.com/actions/checkout/pull/697
run: git fetch --force origin $(git describe --tags):refs/tags/$(git describe --tags) run: git fetch --force origin $(git describe --tags):refs/tags/$(git describe --tags)
...@@ -19,9 +22,6 @@ jobs: ...@@ -19,9 +22,6 @@ jobs:
run: sudo PUBLISH_TAR=1 tests/run-apt run: sudo PUBLISH_TAR=1 tests/run-apt
- name: Create GitHub release - name: Create GitHub release
uses: docker://antonyurchenko/git-release:latest uses: eloquent/github-release-action@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHANGELOG_FILE: "NEWS"
with: with:
args: umockdev-*.tar.xz prerelease: "false"
OBSOLETE: Release news of newer versions are contained in the tag descriptions.
## [0.17.13] - 2022-05-30 ## [0.17.13] - 2022-05-30
- preload: Wrap fstatfs(), to work with systemd 251 also with Python tests - preload: Wrap fstatfs(), to work with systemd 251 also with Python tests
- Fix tests in Gentoo sandbox build - Fix tests in Gentoo sandbox build
......
#!/bin/sh
set -e
# This script does all the steps necessary for doing a new upstream release. It
# should solely be used by upstream developers, distributors do not need to
# worry about it.
# check for anything uncommitted
if LC_MESSAGES=C git status | grep -Eiq 'modified|untracked'; then
echo "untracked/modified files, see git status" >&2
exit 1
fi
git clean -fdx
# update NEWS
version=$(sed -rn '1 { s/^.*\[([0-9.]+)\].*/\1/; p }' NEWS)
[ -n "$version" ] || {
echo "failed to parse version" >&2
exit 1
}
sed -i "s/- UNRELEASED/- $(date '+%Y-%m-%d')/" NEWS
# commit the release and tag
git commit -a -m "release $version"
changes=$(sed -n '/^$/ q; /^- / p' NEWS)
printf "$version\n\n$changes\n" | git tag -s -F- $version
git push
git push --tags
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment