bump-gpui-minor-version

 1#!/usr/bin/env bash
 2
 3
 4# Ensure we're in a clean state on an up-to-date `main` branch.
 5if [[ -n $(git status --short --untracked-files=no) ]]; then
 6  echo "can't bump versions with uncommitted changes"
 7  exit 1
 8fi
 9if [[ $(git rev-parse --abbrev-ref HEAD) != "main" ]]; then
10  echo "this command must be run on main"
11  exit 1
12fi
13git pull -q --ff-only origin main
14
15
16# Parse the current version
17version=$(script/get-crate-version gpui)
18major=$(echo $version | cut -d. -f1)
19minor=$(echo $version | cut -d. -f2)
20next_minor=$(expr $minor + 1)
21
22next_minor_branch_name="bump-gpui-to-v${major}.${next_minor}.0"
23
24git checkout -b ${next_minor_branch_name}
25
26script/lib/bump-version.sh gpui gpui-v "" minor true
27
28git checkout -q main