Skip to content

git_ui: Show copy-SHA button on commit header hover#45478

Merged
danilo-leal merged 4 commits intozed-industries:mainfrom
cppcoffee:copy-sha
Dec 23, 2025
Merged

git_ui: Show copy-SHA button on commit header hover#45478
danilo-leal merged 4 commits intozed-industries:mainfrom
cppcoffee:copy-sha

Conversation

@cppcoffee
Copy link
Contributor

@cppcoffee cppcoffee commented Dec 21, 2025

Release Notes:

  • git: Added the ability to copy a commit's SHA in the commit view.

Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Dec 21, 2025
@github-actions github-actions bot added the community champion Issues filed by our amazing community champions! 🫶 label Dec 21, 2025
@cppcoffee
Copy link
Contributor Author

Before:

2025-12-21.13.08.59.mov

After:

2025-12-21.13.09.36.mov

Copy link
Member

@danilo-leal danilo-leal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! Pushed a commit refining the UI a bit: switched to use ButtonLike and visible_on_hover instead of manually tracking hover, removed the "Commit" text because it's pretty obvious this is the commit SHA, capped the commit SHA to an arbitrary width but added it in full in the tooltip, and made the icon change if the SHA's been copied.

Screenshot.2025-12-23.at.1.59.mp4

@danilo-leal danilo-leal enabled auto-merge (squash) December 23, 2025 17:03
@danilo-leal danilo-leal merged commit 9f90c1a into zed-industries:main Dec 23, 2025
23 checks passed
@github-project-automation github-project-automation bot moved this from Community PRs to Done in Quality Week – December 2025 Dec 23, 2025
@cppcoffee cppcoffee deleted the copy-sha branch December 24, 2025 00:17
rtfeldman pushed a commit that referenced this pull request Jan 5, 2026
Release Notes:

- git: Added the ability to copy a commit's SHA in the commit view.

---------

Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
@williamdes
Copy link
Contributor

Thank you!
Closes #45489

And thank you for the preview videos

LivioGama pushed a commit to LivioGama/zed that referenced this pull request Jan 20, 2026
…5478)

Release Notes:

- git: Added the ability to copy a commit's SHA in the commit view.

---------

Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
LivioGama pushed a commit to LivioGama/zed that referenced this pull request Jan 20, 2026
…5478)

Release Notes:

- git: Added the ability to copy a commit's SHA in the commit view.

---------

Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
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 community champion Issues filed by our amazing community champions! 🫶

Projects

Development

Successfully merging this pull request may close these issues.

4 participants