Skip to content

Feat/1074 branch show current - #1083

Merged
steveukx merged 3 commits into
mainfrom
feat/1074_branch_show_current
Oct 28, 2025
Merged

steveukx merged 3 commits into
mainfrom
feat/1074_branch_show_current

Conversation

@steveukx

Copy link
Copy Markdown
Owner

The response to git branch --show-current is the name of the current branch, with no surrounding white-space (ie: my-new-branch).

Until now the parsers for git.branch assumed either --list (regular or verbose) format or a branch deletion of some kind. Each of which rely on a leading or * to determine whether the branch is the current branch or not.

Adds support for the --show-current option having been passed in by switching out to a different parser that matches with the single line of content.

Closes #1074

@changeset-bot

changeset-bot Bot commented Oct 28, 2025 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: ee9e2ca

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
simple-git Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@steveukx
steveukx merged commit 9872f84 into main Oct 28, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

branch --show-current not working as expected

1 participant