Skip to content

feat(statusline): add git_show_behind config option#156

Merged
st0nefish-ci[bot] merged 1 commit into
masterfrom
feat/statusline-git-show-behind
Jun 18, 2026
Merged

feat(statusline): add git_show_behind config option#156
st0nefish-ci[bot] merged 1 commit into
masterfrom
feat/statusline-git-show-behind

Conversation

@St0nefish

Copy link
Copy Markdown
Owner

Summary

  • Adds git_show_behind boolean config option (default: true) to suppress the ⇣N behind indicator in the git segment
  • Ahead/behind are both computed from local tracking refs — no remote query involved — but behind reflects remote state ("what's on origin you haven't pulled") rather than session work ("what have you committed locally")
  • Sets git_show_behind: false in the user config by default for the maintainer

Test plan

  • Verify ⇡N still appears when commits are ahead of tracking ref
  • Verify ⇣N is hidden when git_show_behind: false in config
  • Verify ⇣N still appears when git_show_behind: true (default)
  • Verify statusline renders correctly with no config file present

🤖 Generated with Claude Code

Adds a `git_show_behind` boolean (default: true) to suppress the ⇣N
behind indicator. Ahead/behind are both computed from local tracking
refs — no remote query — but behind reflects "what's on remote that
you haven't pulled" rather than "what did this session do," which is
a less useful signal in the Claude Code context.

- Add DEFAULT_GIT_SHOW_BEHIND and GIT_SHOW_BEHIND variable
- Wire through load_config from config.json
- Guard ⇣N display in seg_git with GIT_SHOW_BEHIND check
- Bump version 1.1.4 → 1.1.5

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings June 18, 2026 17:33
@St0nefish St0nefish self-assigned this Jun 18, 2026
@st0nefish-ci st0nefish-ci Bot enabled auto-merge June 18, 2026 17:33

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

Adds a new configuration switch to control whether the git segment shows the “behind” (⇣N) indicator, allowing users to hide remote-behind status while keeping other git status indicators.

Changes:

  • Introduces git_show_behind config parsing and gates rendering of the ⇣N indicator on it.
  • Adds new defaults for the option and bumps the plugin version.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
plugins-claude/statusline/scripts/statusline.sh Adds git_show_behind default/config parsing and conditionally renders the behind indicator.
plugins-claude/statusline/.claude-plugin/plugin.json Bumps plugin version to 1.1.5.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

EXTRA_HIDE_ZERO=true
EXTRA_ONLY_BURNING=false
CURRENCY=""
GIT_SHOW_BEHIND=true
v=$(echo "$cfg" | jq -r '.extra_hide_zero // empty' 2>/dev/null) && [[ -n "$v" ]] && EXTRA_HIDE_ZERO="$v"
v=$(echo "$cfg" | jq -r '.extra_only_burning // empty' 2>/dev/null) && [[ -n "$v" ]] && EXTRA_ONLY_BURNING="$v"
v=$(echo "$cfg" | jq -r '.currency // empty' 2>/dev/null) && [[ -n "$v" ]] && CURRENCY="$v"
v=$(echo "$cfg" | jq -r '.git_show_behind // empty' 2>/dev/null) && [[ -n "$v" ]] && GIT_SHOW_BEHIND="$v"
{
"name": "statusline",
"version": "1.1.4",
"version": "1.1.5",
@st0nefish-ci st0nefish-ci Bot merged commit d3011ed into master Jun 18, 2026
7 checks passed
@st0nefish-ci st0nefish-ci Bot deleted the feat/statusline-git-show-behind branch June 18, 2026 17:36
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.

2 participants