Informative git status prompt formatter (xonsh.prompt.gitstatus)

Informative git status prompt formatter

class xonsh.prompt.gitstatus.GitStatus(branch, num_ahead, num_behind, untracked, changed, conflicts, staged, stashed, operations)

Create new instance of GitStatus(branch, num_ahead, num_behind, untracked, changed, conflicts, staged, stashed, operations)

count(value) → integer -- return number of occurrences of value
index(value[, start[, stop]]) → integer -- return first index of value.

Raises ValueError if the value is not present.

branch

Alias for field number 0

changed

Alias for field number 4

conflicts

Alias for field number 5

num_ahead

Alias for field number 1

num_behind

Alias for field number 2

operations

Alias for field number 8

staged

Alias for field number 6

stashed

Alias for field number 7

untracked

Alias for field number 3

xonsh.prompt.gitstatus.gitstatus()[source]

Return namedtuple with fields: branch name, number of ahead commit, number of behind commit, untracked number, changed number, conflicts number, staged number, stashed number, operation.

xonsh.prompt.gitstatus.gitstatus_prompt()[source]

Return str BRANCH|OPERATOR|numbers