@openvcs/git-plugin 0.2.0-nightly.20260507.56 → 0.2.0-nightly.20260508.58
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/bin/plugin-helpers.js +4 -0
- package/package.json +3 -3
- package/src/plugin-helpers.ts +4 -0
package/bin/plugin-helpers.js
CHANGED
|
@@ -83,6 +83,7 @@ export function parseStatusOutput(output) {
|
|
|
83
83
|
const records = output.split('\0').filter(Boolean);
|
|
84
84
|
let ahead = 0;
|
|
85
85
|
let behind = 0;
|
|
86
|
+
let branchOnRemote = false;
|
|
86
87
|
const files = [];
|
|
87
88
|
const summary = {
|
|
88
89
|
untracked: 0,
|
|
@@ -97,6 +98,8 @@ export function parseStatusOutput(output) {
|
|
|
97
98
|
const behindMatch = record.match(/behind\s+(\d+)/);
|
|
98
99
|
ahead = aheadMatch ? Number(aheadMatch[1]) : 0;
|
|
99
100
|
behind = behindMatch ? Number(behindMatch[1]) : 0;
|
|
101
|
+
const trackingMatch = record.match(/^## [^ ]+\.\.\.\S+/);
|
|
102
|
+
branchOnRemote = !!trackingMatch;
|
|
100
103
|
continue;
|
|
101
104
|
}
|
|
102
105
|
if (record.length < 4) {
|
|
@@ -147,6 +150,7 @@ export function parseStatusOutput(output) {
|
|
|
147
150
|
files,
|
|
148
151
|
ahead,
|
|
149
152
|
behind,
|
|
153
|
+
branch_on_remote: branchOnRemote,
|
|
150
154
|
},
|
|
151
155
|
};
|
|
152
156
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openvcs/git-plugin",
|
|
3
|
-
"version": "0.2.0-nightly.
|
|
3
|
+
"version": "0.2.0-nightly.20260508.58",
|
|
4
4
|
"description": "OpenVCS Git plugin - Node.js runtime",
|
|
5
5
|
"license": "GPL-3.0-or-later",
|
|
6
6
|
"homepage": "https://github.com/Open-VCS/OpenVCS-Plugin-Git",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"openvcs": {
|
|
19
19
|
"id": "openvcs.git",
|
|
20
20
|
"name": "Git",
|
|
21
|
-
"version": "0.2.0-nightly.
|
|
21
|
+
"version": "0.2.0-nightly.20260508.58",
|
|
22
22
|
"author": "OpenVCS Contributors",
|
|
23
23
|
"description": "Git VCS backend plugin for OpenVCS",
|
|
24
24
|
"default_enabled": true,
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"build": "node ./node_modules/@openvcs/sdk/bin/openvcs.js build"
|
|
47
47
|
},
|
|
48
48
|
"dependencies": {
|
|
49
|
-
"@openvcs/sdk": "edge"
|
|
49
|
+
"@openvcs/sdk": "^0.3.0-edge.20260506.51"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
52
|
"@types/node": "^25.5.0",
|
package/src/plugin-helpers.ts
CHANGED
|
@@ -111,6 +111,7 @@ export function parseStatusOutput(output: string): StatusParseResult {
|
|
|
111
111
|
const records = output.split('\0').filter(Boolean);
|
|
112
112
|
let ahead = 0;
|
|
113
113
|
let behind = 0;
|
|
114
|
+
let branchOnRemote = false;
|
|
114
115
|
const files: StatusFileEntry[] = [];
|
|
115
116
|
const summary: StatusSummary = {
|
|
116
117
|
untracked: 0,
|
|
@@ -127,6 +128,8 @@ export function parseStatusOutput(output: string): StatusParseResult {
|
|
|
127
128
|
const behindMatch = record.match(/behind\s+(\d+)/);
|
|
128
129
|
ahead = aheadMatch ? Number(aheadMatch[1]) : 0;
|
|
129
130
|
behind = behindMatch ? Number(behindMatch[1]) : 0;
|
|
131
|
+
const trackingMatch = record.match(/^## [^ ]+\.\.\.\S+/);
|
|
132
|
+
branchOnRemote = !!trackingMatch;
|
|
130
133
|
continue;
|
|
131
134
|
}
|
|
132
135
|
|
|
@@ -184,6 +187,7 @@ export function parseStatusOutput(output: string): StatusParseResult {
|
|
|
184
187
|
files,
|
|
185
188
|
ahead,
|
|
186
189
|
behind,
|
|
190
|
+
branch_on_remote: branchOnRemote,
|
|
187
191
|
},
|
|
188
192
|
};
|
|
189
193
|
}
|