how to make repo status appear in posh git (oh-my-posh)

641 Views Asked by At

so basically i want the repository status to be shown and not hidden like this example :

enter image description here

and my terminal without theme shows the repo status but when i apply a theme the numbers (repo status ) disapear like yo see in this pic :

enter image description here

so any fix to that prob ??

1

There are 1 best solutions below

0
On

The theme you have chosen does not include the git add/modified/deleted/untracked counts. For example paradox.omp.json does not include them. To include these counts, you can either:

  1. Choose a theme which does include the full git information, such as peru

or

  1. Edit your oh-my-posh theme file (e.g. paradox.omp.json) to include the git counts. Find the git segment, and add the following lines into the properties section:
"fetch_status": true,
"template": "{{ .HEAD }} {{ .BranchStatus }}{{ if .Working.Changed }} \uF044 {{ .Working.String }}{{ end }}{{ if and (.Staging.Changed) (.Working.Changed) }} |{{ end }}{{ if .Staging.Changed }} \uF046 {{ .Staging.String }}{{ end }}{{ if gt .StashCount 0}} \uF692 {{ .StashCount }}{{ end }}{{ if gt .WorktreeCount 0}} \uf1bb {{ .WorktreeCount }}{{ end }}"