Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

releng/tag-release.sh: relax branch requirement #457

Merged
merged 1 commit into from
Aug 2, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 12 additions & 4 deletions releng/tag-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,18 @@ if [ ! -e bin/generate-zbm ] || [ ! -e docs/CHANGELOG.md ]; then
error "ERROR: run this script from the root of the zfsbootmenu tree"
fi

# Only tag releases from master
if [ "$(git rev-parse --abbrev-ref HEAD)" != "master" ]; then
error "ERROR: will not tag releases on any branch but master"
fi
# Only tag releases from master or a compatible release-tracking branch
case "$(git rev-parse --abbrev-ref HEAD)" in
master)
echo "Tagging release from master branch"
;;
"v${release%.*}.x"|"v${release%%.*}.x")
echo "Tagging release from version-tracking branch"
;;
*)
error "ERROR: attempt to tag release on incompatible branch"
;;
esac

# Only allow changes to CHANGELOG.md when tagging releases
# shellcheck disable=SC2143
Expand Down