pi-git-status-line 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/extensions/git-status-line.ts +2 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -9,6 +9,10 @@ A standalone [Pi](https://github.com/badlogic/pi-mono) package that extends Pi's
|
|
|
9
9
|
|
|
10
10
|
It keeps Pi's existing footer/status line and adds a git summary via `ctx.ui.setStatus(...)`.
|
|
11
11
|
|
|
12
|
+
## Preview
|
|
13
|
+
|
|
14
|
+

|
|
15
|
+
|
|
12
16
|
## Install
|
|
13
17
|
|
|
14
18
|
### From npm
|
|
@@ -181,7 +181,8 @@ function formatGitStatusLine(repo: RepoState, theme: { fg(color: string, text: s
|
|
|
181
181
|
? formatAheadBehind(repo.aheadCount, repo.behindCount, theme)
|
|
182
182
|
: theme.fg("dim", "no upstream");
|
|
183
183
|
|
|
184
|
-
|
|
184
|
+
const segments = [branch, workingTree, sync].join(theme.fg("dim", " · "));
|
|
185
|
+
return ` ${segments}`;
|
|
185
186
|
}
|
|
186
187
|
|
|
187
188
|
function formatAheadBehind(aheadCount: number, behindCount: number, theme: { fg(color: string, text: string): string }) {
|
package/package.json
CHANGED