romkatv / romkatv/gitstatus

How to show full branch name?

Open
#481 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
1.8k
Forks
134
Avg merge
2d 18h
Merged PRs (30d)
1

Description

(I know the project is close-to-unmaintained, but I'm hoping it will be very quick to point me in the right direction for how to solve this.)

I love this project, but the branch name abbreviation drives me absolutely batty. The way we use git at work, all my branches start with the same chiphogg/ prefix, which thus contains zero information. And the end of the branch often includes #PROJ-1234 suffixes, which all kinda blend together. The real useful information is in the middle!

I want to configure the prompt to print the full branch name, always, no matter how long it is. Which pathway(s) are available to me?

  1. Follow the copy-and-modify approach at the end of the bash section
  2. Provide a PR to add a new environment variable that a user can set, to gate what I assume is the truncation code
  3. Fork this project and delete the truncation code
  4. ...something else?

Thanks in advance!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked bash section in the README and gitstatus.prompt.sh lines 55-56, then trace how branch-name truncation reaches the prompt. Compare the copy-and-modify, environment-variable, and fork options described in the issue; done means the prompt can consistently display the full branch name.

Written by the indexing model from the issue text.

Assessment

Tech stack
bash, git, zsh
Domain
cli, tooling
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.