JanDeDobbeleer / oh-my-posh2

A prompt theming engine for Powershell
MIT License
5.19k stars 284 forks source link

brocken git info on one repo #337

Closed hbinkle closed 3 years ago

hbinkle commented 3 years ago

Hi, on one of my repos I have strange broken git info: image any ideas how to get rid of those? I seems like this is caused by missing a pull. I know that there are 4 commits I've not yet pulled. my GitPromptSettings (are still default):

DefaultForegroundColor                    :
BeforeText                                :  [
BeforeForegroundColor                     : Yellow
BeforeBackgroundColor                     :
DelimText                                 :  |
DelimForegroundColor                      : Yellow
DelimBackgroundColor                      :
AfterText                                 : ]
AfterForegroundColor                      : Yellow
AfterBackgroundColor                      :
FileAddedText                             : +
FileModifiedText                          : ~
FileRemovedText                           : -
FileConflictedText                        : !
LocalDefaultStatusSymbol                  :
LocalDefaultStatusForegroundColor         : DarkGreen
LocalDefaultStatusForegroundBrightColor   : Green
LocalDefaultStatusBackgroundColor         :
LocalWorkingStatusSymbol                  : !
LocalWorkingStatusForegroundColor         : DarkRed
LocalWorkingStatusForegroundBrightColor   : Red
LocalWorkingStatusBackgroundColor         :
LocalStagedStatusSymbol                   : ~
LocalStagedStatusForegroundColor          : Cyan
LocalStagedStatusBackgroundColor          :
BranchUntrackedSymbol                     :
BranchForegroundColor                     : Cyan
BranchBackgroundColor                     :
BranchGoneStatusSymbol                    : ×
BranchGoneStatusForegroundColor           : DarkCyan
BranchGoneStatusBackgroundColor           :
BranchIdenticalStatusToSymbol             : ≡
BranchIdenticalStatusToForegroundColor    : Cyan
BranchIdenticalStatusToBackgroundColor    :
BranchAheadStatusSymbol                   : ↑
BranchAheadStatusForegroundColor          : Green
BranchAheadStatusBackgroundColor          :
BranchBehindStatusSymbol                  : ↓
BranchBehindStatusForegroundColor         : Red
BranchBehindStatusBackgroundColor         :
BranchBehindAndAheadStatusSymbol          : ↕
BranchBehindAndAheadStatusForegroundColor : Yellow
BranchBehindAndAheadStatusBackgroundColor :
BeforeIndexText                           :
BeforeIndexForegroundColor                : DarkGreen
BeforeIndexForegroundBrightColor          : Green
BeforeIndexBackgroundColor                :
IndexForegroundColor                      : DarkGreen
IndexForegroundBrightColor                : Green
IndexBackgroundColor                      :
WorkingForegroundColor                    : DarkRed
WorkingForegroundBrightColor              : Red
WorkingBackgroundColor                    :
EnableStashStatus                         : False
BeforeStashText                           :  (
BeforeStashBackgroundColor                :
BeforeStashForegroundColor                : Red
AfterStashText                            : )
AfterStashBackgroundColor                 :
AfterStashForegroundColor                 : Red
StashBackgroundColor                      :
StashForegroundColor                      : Red
ErrorForegroundColor                      : Red
ErrorBackgroundColor                      :
ShowStatusWhenZero                        : True
UntrackedFilesMode                        :
AutoRefreshIndex                          : True
BranchBehindAndAheadDisplay               : Full
EnablePromptStatus                        : True
EnableFileStatus                          : True
EnableFileStatusFromCache                 : False
RepositoriesInWhichToDisableFileStatus    : {}
DescribeStyle                             :
EnableWindowTitle                         : posh~git ~
AdminTitlePrefixText                      : Administrator:
DefaultPromptPrefix                       :
DefaultPromptSuffix                       : $('>' * ($nestedPromptLevel + 1))
DefaultPromptDebugSuffix                  :  [DBG]$('>' * ($nestedPromptLevel + 1))
DefaultPromptEnableTiming                 : False
DefaultPromptPath                         : $(Get-PromptPath)
DefaultPromptAbbreviateHomeDirectory      : False
Debug                                     : False
BranchNameLimit                           : 0
TruncatedBranchSuffix                     : ...
JanDeDobbeleer commented 3 years ago

@hbinkle no idea how this occurs although there were issues with non-native git binaries doing weird stuff. The good news is that this doesn't occur on V3.

hbinkle commented 3 years ago

hm.. in V2 I was able to adjust the prompt output of a theme (e.g. I added ks8 info for current cluster and namespace): image how can I do this in V3 as it's themes are only json files?

JanDeDobbeleer commented 3 years ago

@hbinkle there's the kubectl segment for example. If that's not enough you can always use the environment variable segment and preload some env vars before the redering to contain this context and display it.