From 9999260e9e590247b05ea11b4eb4c8c87fa932e4 Mon Sep 17 00:00:00 2001 From: Jan De Dobbeleer Date: Thu, 20 May 2021 18:42:58 +0200 Subject: [PATCH] feat(git): disable status by default resolves #723 --- docs/docs/segment-git.md | 3 ++- src/segment_git.go | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/docs/segment-git.md b/docs/docs/segment-git.md index d86b30b8..95748988 100644 --- a/docs/docs/segment-git.md +++ b/docs/docs/segment-git.md @@ -24,6 +24,7 @@ Local changes can also shown by default using the following syntax for both the "foreground": "#193549", "background": "#ffeb3b", "properties": { + "display_status": true, "display_stash_count": true, "display_upstream_icon": true } @@ -43,7 +44,7 @@ Local changes can also shown by default using the following syntax for both the ### Status -- display_status: `boolean` - display the local changes or not - defaults to `true` +- display_status: `boolean` - display the local changes or not - defaults to `false` - display_status_detail: `boolean` - display the local changes in detail or not - defaults to `true` - display_stash_count: `boolean` show stash count or not - defaults to `false` - status_separator_icon: `string` icon/text to display between staging and working area changes - defaults to ` |` diff --git a/src/segment_git.go b/src/segment_git.go index d48a09a2..f1cb322c 100644 --- a/src/segment_git.go +++ b/src/segment_git.go @@ -140,7 +140,7 @@ func (g *git) enabled() bool { func (g *git) string() string { statusColorsEnabled := g.props.getBool(StatusColorsEnabled, false) - displayStatus := g.props.getBool(DisplayStatus, true) + displayStatus := g.props.getBool(DisplayStatus, false) if displayStatus || statusColorsEnabled { g.setGitStatus()