Skip to content

git: Fix branch picker creating new branches with refs/head/ prefixed on the branch name#44206

Merged
Anthony-Eid merged 4 commits intomainfrom
fix-branch-picker-create-new-branch
Dec 5, 2025
Merged

git: Fix branch picker creating new branches with refs/head/ prefixed on the branch name#44206
Anthony-Eid merged 4 commits intomainfrom
fix-branch-picker-create-new-branch

Conversation

@Anthony-Eid
Copy link
Contributor

@Anthony-Eid Anthony-Eid commented Dec 5, 2025

The bug was introduced in this recent PR: #42819. Since it's still in nightly, there is no need for release notes.

I also polished the feature a bit by:

  • Ensuring branch names are always a single line so the branch picker's uniform list uses the correct element height.
  • Adding tooltip text for the filter remotes button.
  • Fixing the create branch from default icon showing up for non-new branch entries.

Release Notes:

  • N/A

@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Dec 5, 2025
@Anthony-Eid Anthony-Eid force-pushed the fix-branch-picker-create-new-branch branch from da3f740 to 4ba0ce6 Compare December 5, 2025 12:38
@Anthony-Eid Anthony-Eid marked this pull request as ready for review December 5, 2025 12:40
@Anthony-Eid Anthony-Eid enabled auto-merge (squash) December 5, 2025 12:40
@Anthony-Eid Anthony-Eid merged commit 126d708 into main Dec 5, 2025
37 of 39 checks passed
@Anthony-Eid Anthony-Eid deleted the fix-branch-picker-create-new-branch branch December 5, 2025 12:59
AlpSha pushed a commit to AlpSha/zed that referenced this pull request Dec 5, 2025
… on the branch name (zed-industries#44206)

The bug was introduced in this recent PR:
zed-industries#42819. Since it's still in
nightly, there is no need for release notes.

I also polished the feature a bit by:
- Ensuring branch names are always a single line so the branch picker's
uniform list uses the correct element height.
- Adding tooltip text for the filter remotes button.
- Fixing the create branch from default icon showing up for non-new
branch entries.

Release Notes:

- N/A
danilo-leal added a commit that referenced this pull request Dec 5, 2025
Follow up to #42819 and
#44206.

- Make this picker feel more consistent with other similar pickers
(namely, the project picker)
- Move actions to the footer and toggle them conditionally
- Only show the "Create" and "Create New From: {default}" when we're
selecting the "Create" list item _or_ when that item is the only
visible. This means I'm changing here the state transition to only
change to `NewBranch/NewRemote` if we only have those items available.
- Reuse more UI code and use components when available (e.g.,
`ListHeader`)
- Remove secondary actions from the list item

Next step (in another PR), will be refine the same picker in the
smaller, panel version.


https://github.com/user-attachments/assets/fe72ac06-c1df-4829-a8a4-df8a9222672f

Release Notes:

- N/A
CherryWorm pushed a commit to CherryWorm/zed that referenced this pull request Dec 16, 2025
… on the branch name (zed-industries#44206)

The bug was introduced in this recent PR:
zed-industries#42819. Since it's still in
nightly, there is no need for release notes.

I also polished the feature a bit by:
- Ensuring branch names are always a single line so the branch picker's
uniform list uses the correct element height.
- Adding tooltip text for the filter remotes button.
- Fixing the create branch from default icon showing up for non-new
branch entries.

Release Notes:

- N/A
CherryWorm pushed a commit to CherryWorm/zed that referenced this pull request Dec 16, 2025
Follow up to zed-industries#42819 and
zed-industries#44206.

- Make this picker feel more consistent with other similar pickers
(namely, the project picker)
- Move actions to the footer and toggle them conditionally
- Only show the "Create" and "Create New From: {default}" when we're
selecting the "Create" list item _or_ when that item is the only
visible. This means I'm changing here the state transition to only
change to `NewBranch/NewRemote` if we only have those items available.
- Reuse more UI code and use components when available (e.g.,
`ListHeader`)
- Remove secondary actions from the list item

Next step (in another PR), will be refine the same picker in the
smaller, panel version.


https://github.com/user-attachments/assets/fe72ac06-c1df-4829-a8a4-df8a9222672f

Release Notes:

- N/A
someone13574 pushed a commit to someone13574/zed that referenced this pull request Dec 16, 2025
… on the branch name (zed-industries#44206)

The bug was introduced in this recent PR:
zed-industries#42819. Since it's still in
nightly, there is no need for release notes.

I also polished the feature a bit by:
- Ensuring branch names are always a single line so the branch picker's
uniform list uses the correct element height.
- Adding tooltip text for the filter remotes button.
- Fixing the create branch from default icon showing up for non-new
branch entries.

Release Notes:

- N/A
someone13574 pushed a commit to someone13574/zed that referenced this pull request Dec 16, 2025
Follow up to zed-industries#42819 and
zed-industries#44206.

- Make this picker feel more consistent with other similar pickers
(namely, the project picker)
- Move actions to the footer and toggle them conditionally
- Only show the "Create" and "Create New From: {default}" when we're
selecting the "Create" list item _or_ when that item is the only
visible. This means I'm changing here the state transition to only
change to `NewBranch/NewRemote` if we only have those items available.
- Reuse more UI code and use components when available (e.g.,
`ListHeader`)
- Remove secondary actions from the list item

Next step (in another PR), will be refine the same picker in the
smaller, panel version.


https://github.com/user-attachments/assets/fe72ac06-c1df-4829-a8a4-df8a9222672f

Release Notes:

- N/A
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed The user has signed the Contributor License Agreement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant