question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Only branch name is shown, but nothing else

See original GitHub issue

Hi,

I’m new to powerline, so I might have misconfigured it, but I can’t get powerline-gitstatus to show anything but the branch name.

Contents of ~/.config/powerline/config.json:

{
	"ext": {
		"shell": {
			"colorscheme": "default",
			"theme": "default_leftonly"
		}
	}
}

The ~/.config/powerline/themes/shell/default.json and ~/.config/powerline/colorschemes/default.json are copied from the powerline-gitstatus readme as-is.

The output of git status --branch --porcelain is:

## master...origin/master [ahead 2]
 M Doxyfile

However, powerline-gitstatus looks like this: http://imgur.com/a/uNjWo ― the branch name is shown, but it doesn’t say how many modified files I have or how many commits I’m ahead of origin/master.

I have git version 2.13.5.

What am I doing wrong?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:1
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
hypr2771commented, Nov 20, 2018

Just for the record and to avoid people crawling each issues 1 by 1 : I had the same issue, but found the solution in here : https://github.com/jaspernbrouwer/powerline-gitstatus/issues/13

For the record, I came across it by running powerline-lint

1reaction
rgolanghcommented, Sep 26, 2017

@jaspernbrouwer thanks, I got it working now by

  • using default and not left
  • adding powerline_gitstatus.gitstatus to the ‘left’ section of the shell/default.json

I created colorschemes and shell directories under my home dir

mkdir -p ~/.config/powerline/colorschemes  ~/.config/powerline/themes/shell

Place powerline_gitstatus.gitstatus on the left section in shell/default.json and with priority 10

Here is the complete ~/.config/powerline/themes/shell/default.json

{
	"segments": {
		"left": [
			{
				"function": "powerline.segments.shell.mode"
			},
			{
				"function": "powerline.segments.common.net.hostname",
				"priority": 10
			},
			{
				"function": "powerline.segments.common.env.user",
				"priority": 30
			},
			{
				"function": "powerline.segments.common.env.virtualenv",
				"priority": 50
			},
			{
				"function": "powerline.segments.shell.cwd",
				"priority": 10
			},
			{
				"function": "powerline.segments.shell.jobnum",
				"priority": 20
			},
                        {
				"function": "powerline_gitstatus.gitstatus",
				"priority": 10
			}
		],
		"right": [
			{
				"function": "powerline.segments.shell.last_pipe_status",
				"priority": 10
			},
			{
				"function": "powerline.segments.common.vcs.stash",
				"priority": 50
			},
			{
				"function": "powerline.segments.common.vcs.branch",
				"priority": 40
			}
		]
	}
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

git branch is not showing all the branches - Stack Overflow
Use git branch -a to see all branches in repo and then you can use git checkout branchname to checkout to respective branch....
Read more >
git-branch Documentation - Git
With --contains , shows only the branches that contain the named commit (in other words, the branches whose tip commits are descendants of...
Read more >
Branches - GitLab Docs
A branch is a version of a project's working tree. You create a branch for each set of related changes you make. This...
Read more >
Using branch permissions | Bitbucket Data Center and Server ...
With branch permissions you can control the actions users can perform on a single branch, branch type, or branch pattern within a repository...
Read more >
Git Delete Branch How-To, for Both Local and Remote
git push --delete <remote name> <branch name> ... you can only move backward, so there's no way for you to reach the commits...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found