Add Hazel build info to bottom bar of editor#2315
Conversation
Generates a BuildInfo module at build time via a dune rule that runs git rev-parse and git status, then renders branch@shortsha on the right side of #bottom-bar. Dirty working trees show a pencil glyph and italic text instead of a clickable GitHub commit link. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## dev #2315 +/- ##
=======================================
Coverage 50.91% 50.92%
=======================================
Files 300 300
Lines 39867 39872 +5
=======================================
+ Hits 20300 20303 +3
- Misses 19567 19569 +2
🚀 New features to boost your workflow:
|
|
My ideas: It would be nice if the branch was linkable separate to the commit so you can get to the branch url in github or the specific commit. @disconcision's original notes to me:
I think that on |
| ++ (BuildInfo.dirty ? "-dirty" : ""); | ||
| let inner = text(label); | ||
| let body = | ||
| BuildInfo.dirty || BuildInfo.ahead |
There was a problem hiding this comment.
I think we should consider doing another class/symbol to represent that this is ahead rather than just using dirty since it's helpful to have a link to an existing commit on github even if there's local changes.
I'm also somewhat ambivalent of removing the link if the commit isn't on github since it only happens in dev workflows and the link starts working after you push. I could see it either way though.
|
I like the look of the bar now. It's a little confusing that if you click on it it doesn't go away because you're still hovering it. I wonder if we can make it go away and just reappear when you hover again. @disconcision might have more styling opinions though. Sidenote: this also links to the local branch name on github which could not be the upstream branch name. I don't think many people are doing this so I'm not really concerned but it could be something we try to handle. |


Displays the git information for the current Hazel build in the bottom right of the editor, in the format
branch@short-sha(with a hyperlink to GitHub), and an additional-dirtysuffix if there are additional uncommitted local changes. Originally written by @7h3kk1d, but since it would be helpful to add this functionality for agent evaluation, I want to help this get merged as well.