File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change 22
33set -eu -o pipefail
44
5+ # Check that we're not on the main branch
6+ current_branch=$( git branch --show-current)
7+ if [ " $current_branch " = " main" ]; then
8+ echo " Error: Releases should not be done directly on the main branch."
9+ echo " Please create a release branch and run this script from there."
10+ exit 1
11+ fi
12+
13+ # Fetch latest changes and check that we're not behind origin/main
14+ echo " Fetching from origin..."
15+ git fetch origin
16+
17+ if ! git merge-base --is-ancestor origin/main HEAD; then
18+ echo " Error: Current branch is behind origin/main."
19+ echo " Please merge or rebase with origin/main before releasing."
20+ exit 1
21+ fi
22+
523changelog=$( cat Changes.md)
624
725regex=' ## ([0-9]+\.[0-9]+\.[0-9]+) - ([0-9]{4}-[0-9]{2}-[0-9]{2})
You can’t perform that action at this time.
0 commit comments