v0.16.0
This release contains a number of improvements.
Full list available below, but a couple highlights:
- Custom shorthands now support shelling out to external commands by prefixing them with
!--similarly to Git aliases. - A number of fixes have been made to make git-spice commands play nicer with Git worktrees.
submitcommands now support a--labelflag and configuration option that adds labels to GitHub Pull Requests and GitLab Merge Requests upon submission.submitcommands can now be configured to open a web browser only for newly created CRs. Usegit config --global spice.submit.web createto opt into this behavior.
Added
- Add support for custom shorthands to invoke external shell commands.
- submit: Add -l/--label flag and accompanying 'spice.submit.label' configuration option to add labels to created/updated CRs.
- stack delete: New command to delete all branches in the current branch's stack.
- upstack delete: New command to delete all branches upstack from the current branch, not including the current branch.
- repo restack: New command to restack all tracked branches.
- submit: Add 'spice.submit.draft' configuration option to control the default value of --draft/--no-draft for new CRs.
- checkout: Add 'spice.checkout.verbose' configuration option to report the branch name checked out. This works for
up,down,top, andbottomcommands too. - submit: Add 'spice.submit.navigationCommentSync' configuration option to control which branches' navigation comments are updated when a change is submitted.
- stack restack: Add --branch option to restack the stack of a different branch.
- branch squash: Add --branch option to specify the branch being targeted.
- branch squash: Add --no-edit flag to use generated commit message without opening an editor.
Changed
- submit: Support a value of 'created' for the --web flag and the 'spice.submit.web' configuration option. This will result in only new CRs being opened in a browser.
- branch fold: Confirm user intent when called from a branch based directly on the trunk branch. This prevents accidentally folding changes into trunk.
- repo init: Warn when trunk is behind upstream at initialization time. This prevents issues caused by trying to rebase newer feature branches on top of a severely old trunk branch.
- branch squash: Use a commit message template similar to Git. Information from git-spice is commented out and commit messages are presented in oldest-to-newest order.
Fixed
- repo init: Validate that the trunk branch is a local branch.
- repo sync: Don't fail if a merged branch is checked out in another worktree. Log a message and skip it.
- branch delete: Don't fail if the branch to check out after deletion is checked out in another worktree. Log a message and detach HEAD.
- restack: If a branch planned to be restacked is checked out in another worktree, don't attempt to restack it or its upstacks.
- log long: Fix incorrect list of commits listed in the log following a manual rebase operation.
- branch squash: Fix no-op commit left behind in some scenarios when 'branch squash' is run after a manual rebase.
- Fix concurrent updates to git-spice's state causing "cannot lock ref" warnings.
- up: Don't re-load state repeatedly when going up >1 branches. This is >8x faster in degenerate cases.
- stack restack: Don't reload state information to determine upstack/downstack branches.