@jmfederico/pi-web 1.202609.0 → 1.202609.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 +3 -3
- package/dist/.plugins-ready +1 -0
- package/dist/cli.js +5 -2
- package/dist/cli.js.map +1 -1
- package/dist/client/assets/index-AroYaCLx.js +4130 -0
- package/dist/client/assets/vendor-editor-core-YWog6mAR.js +10 -0
- package/dist/client/assets/vendor-editor-languages-DOCw3vc9.js +28 -0
- package/dist/client/index.html +4 -4
- package/dist/docker/piWebDockerCommandPlan.js +9 -1
- package/dist/docker/piWebDockerCommandPlan.js.map +1 -1
- package/dist/nativeServices/installedServiceDefinitions.js +24 -17
- package/dist/nativeServices/installedServiceDefinitions.js.map +1 -1
- package/dist/nativeServices/serviceAction.js +38 -26
- package/dist/nativeServices/serviceAction.js.map +1 -1
- package/dist/nativeServices/servicePlan.js +3 -3
- package/dist/nativeServices/servicePlan.js.map +1 -1
- package/dist/pi-packages/captains-log/README.md +11 -0
- package/dist/pi-packages/captains-log/dist/browser/channelProtocol.js +29 -0
- package/dist/pi-packages/captains-log/dist/browser/index.js +144 -0
- package/dist/pi-packages/captains-log/dist/browser/markdown.js +67 -0
- package/dist/pi-packages/captains-log/dist/browser/panel.js +105 -0
- package/dist/pi-packages/captains-log/dist/browser/protocol.js +26 -0
- package/dist/pi-packages/captains-log/dist/companion.js +126 -0
- package/dist/pi-packages/captains-log/dist/roundtrip.js +62 -0
- package/dist/pi-packages/captains-log/dist/server.js +210 -0
- package/dist/pi-packages/captains-log/dist/store.js +75 -0
- package/dist/pi-packages/captains-log/docs/usage.md +30 -0
- package/dist/pi-packages/captains-log/package.json +35 -0
- package/dist/pi-packages/captains-log/tsconfig.json +21 -0
- package/dist/pi-packages/captains-log/vite.config.mjs +28 -0
- package/dist/pi-packages/relays/pi-web-plugin.js +1 -1
- package/dist/pi-packages/relays/prompts/relay.md +1 -1
- package/dist/pi-packages/relays/skills/relay-runner/SKILL.md +21 -13
- package/dist/pi-web-plugins/files/browser/assets/files-icon-DZObYhxb.svg +3 -0
- package/dist/pi-web-plugins/files/browser/pi-web-plugin.js +439 -0
- package/dist/pi-web-plugins/files/package.json +15 -0
- package/dist/pi-web-plugins/git/browser/git-panel.js +54 -24
- package/dist/pi-web-plugins/git/browser/pi-web-plugin.js +1 -1
- package/dist/pi-web-plugins/git/git-backend.js +5 -5
- package/dist/pi-web-plugins/git/server-plugin.js +5 -3
- package/dist/pi-web-plugins/info/pi-web-plugin.js +1 -1
- package/dist/pi-web-plugins/mermaid/browser/mermaid-engine.js +3590 -0
- package/dist/pi-web-plugins/mermaid/browser/pi-web-plugin.js +6 -0
- package/dist/pi-web-plugins/mermaid/package.json +13 -0
- package/dist/pi-web-plugins/terminal/browser/pi-web-plugin.js +210 -0
- package/dist/pi-web-plugins/terminal/package.json +16 -0
- package/dist/pi-web-plugins/terminal/server-plugin.js +365 -0
- package/dist/{server/terminals → pi-web-plugins/terminal}/terminalService.js +159 -79
- package/dist/pi-web-plugins/updates/pi-web-plugin.js +1 -1
- package/dist/pi-web-plugins/workspace-tasks/pi-web-plugin.js +1 -1
- package/dist/piWebVersionReport.js +12 -4
- package/dist/piWebVersionReport.js.map +1 -1
- package/dist/plugin-api.d.ts +222 -23
- package/dist/plugin-api.js +1 -0
- package/dist/pluginRecoveryCli.js +3 -2
- package/dist/pluginRecoveryCli.js.map +1 -1
- package/dist/server/activity/workspaceActivityService.js.map +1 -1
- package/dist/server/app.js +20 -9
- package/dist/server/app.js.map +1 -1
- package/dist/server/knownPiPackages.js +12 -0
- package/dist/server/knownPiPackages.js.map +1 -0
- package/dist/server/machines/machineClient.js +2 -2
- package/dist/server/machines/machineClient.js.map +1 -1
- package/dist/server/machines/machinePluginProxyRoutes.js +53 -11
- package/dist/server/machines/machinePluginProxyRoutes.js.map +1 -1
- package/dist/server/machines/machineProxyRoutes.js +70 -7
- package/dist/server/machines/machineProxyRoutes.js.map +1 -1
- package/dist/server/notices/serverNoticeStore.js +45 -4
- package/dist/server/notices/serverNoticeStore.js.map +1 -1
- package/dist/server/piPackageService.js +5 -5
- package/dist/server/piPackageService.js.map +1 -1
- package/dist/server/piWebPluginCatalog.js +46 -12
- package/dist/server/piWebPluginCatalog.js.map +1 -1
- package/dist/server/piWebPluginLifecycle.js +26 -3
- package/dist/server/piWebPluginLifecycle.js.map +1 -1
- package/dist/server/piWebPluginService.js +37 -2
- package/dist/server/piWebPluginService.js.map +1 -1
- package/dist/server/pluginCallbackDrain.js +35 -0
- package/dist/server/pluginCallbackDrain.js.map +1 -0
- package/dist/server/plugins/pluginBackendChannelProxyAdmission.js +84 -0
- package/dist/server/plugins/pluginBackendChannelProxyAdmission.js.map +1 -0
- package/dist/server/plugins/pluginBackendChannelProxyCoordinator.js +234 -0
- package/dist/server/plugins/pluginBackendChannelProxyCoordinator.js.map +1 -0
- package/dist/server/plugins/pluginBackendChannelProxyRoutes.js +52 -0
- package/dist/server/plugins/pluginBackendChannelProxyRoutes.js.map +1 -0
- package/dist/server/plugins/pluginBackendProxyRoutes.js +38 -31
- package/dist/server/plugins/pluginBackendProxyRoutes.js.map +1 -1
- package/dist/server/plugins/pluginBackendRegistry.js +740 -0
- package/dist/server/plugins/pluginBackendRegistry.js.map +1 -0
- package/dist/server/plugins/serverPluginPiSessionEventsCapability.js +34 -0
- package/dist/server/plugins/serverPluginPiSessionEventsCapability.js.map +1 -0
- package/dist/server/plugins/serverPluginPiSessionsCapability.js +185 -0
- package/dist/server/plugins/serverPluginPiSessionsCapability.js.map +1 -0
- package/dist/server/plugins/serverPluginRuntime.js +1028 -107
- package/dist/server/plugins/serverPluginRuntime.js.map +1 -1
- package/dist/server/plugins/serverPluginWorkspacesCapability.js +114 -0
- package/dist/server/plugins/serverPluginWorkspacesCapability.js.map +1 -0
- package/dist/server/sessiond/pluginBackendChannelRoutes.js +393 -0
- package/dist/server/sessiond/pluginBackendChannelRoutes.js.map +1 -0
- package/dist/server/sessiond/pluginBackendRoutes.js +10 -7
- package/dist/server/sessiond/pluginBackendRoutes.js.map +1 -1
- package/dist/server/sessiond/sessionDaemonShutdown.js +9 -2
- package/dist/server/sessiond/sessionDaemonShutdown.js.map +1 -1
- package/dist/server/sessiond.js +71 -21
- package/dist/server/sessiond.js.map +1 -1
- package/dist/server/sessions/builtinCommands.js +2 -2
- package/dist/server/sessions/builtinCommands.js.map +1 -1
- package/dist/server/sessions/clientSessionPreview.js +14 -0
- package/dist/server/sessions/clientSessionPreview.js.map +1 -0
- package/dist/server/sessions/piSessionEventConnections.js +65 -0
- package/dist/server/sessions/piSessionEventConnections.js.map +1 -0
- package/dist/server/sessions/piSessionService.js +269 -86
- package/dist/server/sessions/piSessionService.js.map +1 -1
- package/dist/server/sessions/sessionActivityMarker.js +105 -0
- package/dist/server/sessions/sessionActivityMarker.js.map +1 -0
- package/dist/server/sessions/sessionEnvironmentFacts.js +5 -4
- package/dist/server/sessions/sessionEnvironmentFacts.js.map +1 -1
- package/dist/server/sessions/sessionNameGenerator.js +3 -2
- package/dist/server/sessions/sessionNameGenerator.js.map +1 -1
- package/dist/server/sessions/sessionRoutes.js +18 -0
- package/dist/server/sessions/sessionRoutes.js.map +1 -1
- package/dist/server/sessions/spawnSessionTool.js +1 -1
- package/dist/server/sessions/spawnSessionTool.js.map +1 -1
- package/dist/server/sessions/spawnSubsessionTool.js +1 -1
- package/dist/server/sessions/spawnSubsessionTool.js.map +1 -1
- package/dist/server/sessions/transcriptMessages.js +54 -0
- package/dist/server/sessions/transcriptMessages.js.map +1 -0
- package/dist/server/terminals/requiredTerminalService.js +103 -0
- package/dist/server/terminals/requiredTerminalService.js.map +1 -0
- package/dist/server/webSocketBridge.js +339 -0
- package/dist/server/webSocketBridge.js.map +1 -1
- package/dist/server/workspaces/sessionDaemonWorkspaceCatalog.js +23 -3
- package/dist/server/workspaces/sessionDaemonWorkspaceCatalog.js.map +1 -1
- package/dist/server/workspaces/workspaceCatalog.js +3 -1
- package/dist/server/workspaces/workspaceCatalog.js.map +1 -1
- package/dist/server/workspaces/workspaceProviderRegistry.js +64 -149
- package/dist/server/workspaces/workspaceProviderRegistry.js.map +1 -1
- package/dist/server/workspaces/workspaceRemovalService.js +23 -1
- package/dist/server/workspaces/workspaceRemovalService.js.map +1 -1
- package/dist/server-plugin-api.d.ts +216 -22
- package/dist/server-plugin-api.js +319 -2
- package/dist/server-plugin-api.js.map +1 -1
- package/dist/serverPluginRecovery.js +4 -0
- package/dist/serverPluginRecovery.js.map +1 -1
- package/dist/sessiond/sessionDaemonClient.js +3 -3
- package/dist/sessiond/sessionDaemonClient.js.map +1 -1
- package/dist/shared/apiTypes.js +1 -1
- package/dist/shared/apiTypes.js.map +1 -1
- package/dist/shared/federatedRoutes.js +45 -17
- package/dist/shared/federatedRoutes.js.map +1 -1
- package/dist/shared/machinePluginIds.js +28 -7
- package/dist/shared/machinePluginIds.js.map +1 -1
- package/dist/shared/pluginApiTypes.d.ts +21 -1
- package/dist/shared/pluginApiTypes.js +0 -1
- package/dist/shared/pluginBackendProtocol.js +163 -2
- package/dist/shared/pluginBackendProtocol.js.map +1 -1
- package/dist/shared/pluginIds.js +8 -1
- package/dist/shared/pluginIds.js.map +1 -1
- package/dist/shared/requiredTerminalPlugin.js +6 -0
- package/dist/shared/requiredTerminalPlugin.js.map +1 -0
- package/dist/shared/serverNoticeContract.js +88 -0
- package/dist/shared/serverNoticeContract.js.map +1 -0
- package/dist/shared/sessionDefaults.js +41 -0
- package/dist/shared/sessionDefaults.js.map +1 -0
- package/docs/config.md +50 -36
- package/docs/plugins.md +146 -1217
- package/examples/session-bridge-plugin/README.md +20 -0
- package/examples/session-bridge-plugin/docs/usage.md +54 -0
- package/examples/session-bridge-plugin/package.json +26 -0
- package/examples/session-bridge-plugin/src/browser/index.ts +84 -0
- package/examples/session-bridge-plugin/src/browser/protocol.ts +24 -0
- package/examples/session-bridge-plugin/src/companion.ts +65 -0
- package/examples/session-bridge-plugin/src/reviewRun.ts +39 -0
- package/examples/session-bridge-plugin/src/server.ts +85 -0
- package/examples/session-bridge-plugin/src/store.ts +57 -0
- package/examples/session-bridge-plugin/tsconfig.json +21 -0
- package/examples/workspace-provider-plugin/README.md +4 -4
- package/examples/workspace-provider-plugin/package.json +1 -1
- package/examples/workspace-provider-plugin/src/browser/index.ts +9 -9
- package/examples/workspace-provider-plugin/src/server.ts +15 -11
- package/package.json +17 -11
- package/dist/client/assets/CodeViewer-CGAlg9S8.js +0 -4
- package/dist/client/assets/TerminalPanel-xhJRhOas.js +0 -187
- package/dist/client/assets/index-DXQKhn1P.js +0 -4326
- package/dist/client/assets/vendor-editor-core-CXO8gGab.js +0 -12
- package/dist/client/assets/vendor-editor-languages-CpW4sJsX.js +0 -46
- package/dist/client/assets/vendor-editor-legacy-CYBnW6ZU.js +0 -1
- package/dist/client/assets/vendor-terminal-BrP-ENHg.css +0 -1
- package/dist/client/assets/vendor-terminal-D8k4UKM2.js +0 -35
- package/dist/server/terminalProxyRoutes.js +0 -141
- package/dist/server/terminalProxyRoutes.js.map +0 -1
- package/dist/server/terminals/terminalRoutes.js +0 -155
- package/dist/server/terminals/terminalRoutes.js.map +0 -1
- package/dist/server/terminals/terminalService.js.map +0 -1
- package/dist/server/terminals/terminalSize.js +0 -17
- package/dist/server/terminals/terminalSize.js.map +0 -1
|
@@ -70,7 +70,7 @@ class GitUiController {
|
|
|
70
70
|
this.requestRender(this.stateFor(context));
|
|
71
71
|
}
|
|
72
72
|
poll(context) {
|
|
73
|
-
void this.refresh(context);
|
|
73
|
+
void this.refresh(context, true);
|
|
74
74
|
}
|
|
75
75
|
invalidate(context) {
|
|
76
76
|
if (!this.isOwnedWorkspace(context.workspace))
|
|
@@ -80,12 +80,24 @@ class GitUiController {
|
|
|
80
80
|
this.requestRender(state);
|
|
81
81
|
return this.refresh(context);
|
|
82
82
|
}
|
|
83
|
-
refresh(context) {
|
|
83
|
+
refresh(context, background = false) {
|
|
84
84
|
const state = this.stateFor(context);
|
|
85
|
-
if (state.statusRequest !== undefined)
|
|
85
|
+
if (state.statusRequest !== undefined) {
|
|
86
|
+
if (!background && !state.statusLoading) {
|
|
87
|
+
state.statusLoading = true;
|
|
88
|
+
this.requestRender(state);
|
|
89
|
+
}
|
|
86
90
|
return state.statusRequest;
|
|
87
|
-
|
|
88
|
-
|
|
91
|
+
}
|
|
92
|
+
const previousStatus = state.status;
|
|
93
|
+
const previousError = state.error;
|
|
94
|
+
const previousStale = state.stale;
|
|
95
|
+
const previousPath = state.selectedDiffPath;
|
|
96
|
+
const showLoading = !background || state.status === undefined;
|
|
97
|
+
if (showLoading) {
|
|
98
|
+
state.statusLoading = true;
|
|
99
|
+
this.requestRender(state);
|
|
100
|
+
}
|
|
89
101
|
const request = requestGitBackend(context, GIT_STATUS_OPERATION, null)
|
|
90
102
|
.then(parseGitStatusResponse)
|
|
91
103
|
.then(async (status) => {
|
|
@@ -93,14 +105,17 @@ class GitUiController {
|
|
|
93
105
|
return;
|
|
94
106
|
state.status = state.status?.hash === status.hash ? state.status : status;
|
|
95
107
|
state.stale = false;
|
|
96
|
-
state.error = undefined;
|
|
97
108
|
const path = state.selectedDiffPath;
|
|
98
|
-
if (path
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
this.
|
|
102
|
-
|
|
103
|
-
|
|
109
|
+
if (path !== undefined && status.files.some((file) => file.path === path)
|
|
110
|
+
&& this.connectedWorkspaceKey === workspaceContextKey(context)) {
|
|
111
|
+
// Let the diff result resolve errors without briefly clearing a persistent failure.
|
|
112
|
+
await this.refreshDiff(state, path, context, background);
|
|
113
|
+
}
|
|
114
|
+
else {
|
|
115
|
+
state.error = undefined;
|
|
116
|
+
if (path !== undefined && !status.files.some((file) => file.path === path))
|
|
117
|
+
this.clearSelection(state, true);
|
|
118
|
+
}
|
|
104
119
|
})
|
|
105
120
|
.catch((error) => {
|
|
106
121
|
if (state.retained)
|
|
@@ -110,8 +125,11 @@ class GitUiController {
|
|
|
110
125
|
if (state.statusRequest !== request)
|
|
111
126
|
return;
|
|
112
127
|
state.statusRequest = undefined;
|
|
128
|
+
const wasLoading = state.statusLoading;
|
|
113
129
|
state.statusLoading = false;
|
|
114
|
-
|
|
130
|
+
if (wasLoading || previousStatus !== state.status || previousError !== state.error
|
|
131
|
+
|| previousStale !== state.stale || previousPath !== state.selectedDiffPath)
|
|
132
|
+
this.requestRender(state);
|
|
115
133
|
});
|
|
116
134
|
state.statusRequest = request;
|
|
117
135
|
return request;
|
|
@@ -248,11 +266,17 @@ class GitUiController {
|
|
|
248
266
|
this.route.write(undefined, { replace: true });
|
|
249
267
|
}
|
|
250
268
|
}
|
|
251
|
-
async refreshDiff(state, path, context) {
|
|
269
|
+
async refreshDiff(state, path, context, background = false) {
|
|
252
270
|
const sequence = state.diffRequestSequence + 1;
|
|
253
271
|
state.diffRequestSequence = sequence;
|
|
254
|
-
|
|
255
|
-
|
|
272
|
+
const previousDiff = state.selectedDiff;
|
|
273
|
+
const previousStagedDiff = state.selectedStagedDiff;
|
|
274
|
+
const previousError = state.error;
|
|
275
|
+
const showLoading = !background || previousDiff === undefined || previousStagedDiff === undefined;
|
|
276
|
+
if (showLoading) {
|
|
277
|
+
state.diffLoading = true;
|
|
278
|
+
this.requestRender(state);
|
|
279
|
+
}
|
|
256
280
|
try {
|
|
257
281
|
const [selectedDiff, selectedStagedDiff] = await Promise.all([
|
|
258
282
|
requestGitBackend(context, GIT_DIFF_OPERATION, { path }).then(parseGitDiffResponse),
|
|
@@ -271,8 +295,11 @@ class GitUiController {
|
|
|
271
295
|
}
|
|
272
296
|
finally {
|
|
273
297
|
if (state.retained && state.diffRequestSequence === sequence && state.selectedDiffPath === path) {
|
|
298
|
+
const wasLoading = state.diffLoading;
|
|
274
299
|
state.diffLoading = false;
|
|
275
|
-
|
|
300
|
+
if (wasLoading || previousDiff !== state.selectedDiff || previousStagedDiff !== state.selectedStagedDiff
|
|
301
|
+
|| previousError !== state.error)
|
|
302
|
+
this.requestRender(state);
|
|
276
303
|
}
|
|
277
304
|
}
|
|
278
305
|
}
|
|
@@ -291,7 +318,7 @@ function createGitActions(panelId, controller) {
|
|
|
291
318
|
shortcutAliases: ["core:view.git"],
|
|
292
319
|
group: "Navigation",
|
|
293
320
|
enabled: hasGitWorkspace,
|
|
294
|
-
run: (context) => { context.
|
|
321
|
+
run: (context) => { context.selectWorkspaceTool(panelId); },
|
|
295
322
|
},
|
|
296
323
|
{
|
|
297
324
|
id: "workspace.refresh-git",
|
|
@@ -326,10 +353,10 @@ function createGitPanel(html, svg, controller) {
|
|
|
326
353
|
};
|
|
327
354
|
}
|
|
328
355
|
function requestGitBackend(context, operation, input) {
|
|
329
|
-
if (context.
|
|
356
|
+
if (context.peer?.request === undefined) {
|
|
330
357
|
return Promise.reject(new Error("Git workspace backend is unavailable. Update and restart PI WEB on this machine, then reload the browser."));
|
|
331
358
|
}
|
|
332
|
-
return context.
|
|
359
|
+
return context.peer.request(operation, input);
|
|
333
360
|
}
|
|
334
361
|
function renderGitPanel(html, controller, context) {
|
|
335
362
|
const state = controller.state(context);
|
|
@@ -551,10 +578,13 @@ function formatLineNumber(lineNumber) {
|
|
|
551
578
|
return lineNumber === undefined ? "" : String(lineNumber);
|
|
552
579
|
}
|
|
553
580
|
function createDiffView(response, previous) {
|
|
554
|
-
|
|
555
|
-
response,
|
|
556
|
-
|
|
557
|
-
|
|
581
|
+
if (previous?.response.hash !== response.hash)
|
|
582
|
+
return { response, lines: undefined };
|
|
583
|
+
// The hash covers diff text, not the metadata displayed beside it.
|
|
584
|
+
if (previous.response.path === response.path && previous.response.staged === response.staged
|
|
585
|
+
&& previous.response.truncated === response.truncated)
|
|
586
|
+
return previous;
|
|
587
|
+
return { response, lines: previous.lines };
|
|
558
588
|
}
|
|
559
589
|
function workspaceContextKey(context) {
|
|
560
590
|
return JSON.stringify([context.machine.id, context.workspace.projectId, context.workspace.id]);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated from pi-web-plugins/git/browser/pi-web-plugin.ts. Do not edit directly.
|
|
2
2
|
import { createGitBrowserContributions } from "./git-panel.js";
|
|
3
3
|
const plugin = {
|
|
4
|
-
apiVersion:
|
|
4
|
+
apiVersion: 4,
|
|
5
5
|
name: "Git",
|
|
6
6
|
activate: ({ pluginId, runtimePluginId, html, svg }) => ({
|
|
7
7
|
contributions: createGitBrowserContributions(pluginId, runtimePluginId, html, svg),
|
|
@@ -15,15 +15,15 @@ const GIT_LOCAL_ENV_VARS = Object.freeze([
|
|
|
15
15
|
"GIT_QUARANTINE_PATH",
|
|
16
16
|
"GIT_WORK_TREE",
|
|
17
17
|
]);
|
|
18
|
-
/** Dispatch the Git
|
|
18
|
+
/** Dispatch the Git status/diff schema through the package peer request seam. */
|
|
19
19
|
export async function requestGitBackend(activationContext, request) {
|
|
20
20
|
const runGit = createGitRunner(activationContext, request.signal);
|
|
21
21
|
if (request.operation === GIT_STATUS_OPERATION) {
|
|
22
22
|
requireStatusInput(request.input);
|
|
23
|
-
return
|
|
23
|
+
return statusPeerResponse(await gitStatusWithRunner(runGit, request.workspace.path));
|
|
24
24
|
}
|
|
25
25
|
if (request.operation === GIT_DIFF_OPERATION) {
|
|
26
|
-
return
|
|
26
|
+
return diffPeerResponse(await gitDiffWithRunner(runGit, request.workspace.path, parseDiffInput(request.input)));
|
|
27
27
|
}
|
|
28
28
|
throw new Error(`Unsupported Git workspace backend operation: ${request.operation}`);
|
|
29
29
|
}
|
|
@@ -351,7 +351,7 @@ function displayFromCommit(headOid) {
|
|
|
351
351
|
function hash(value) {
|
|
352
352
|
return createHash("sha1").update(value).digest("hex");
|
|
353
353
|
}
|
|
354
|
-
function
|
|
354
|
+
function statusPeerResponse(status) {
|
|
355
355
|
return {
|
|
356
356
|
isGitRepo: status.isGitRepo,
|
|
357
357
|
hash: status.hash,
|
|
@@ -370,7 +370,7 @@ function statusProviderResponse(status) {
|
|
|
370
370
|
submodules: status.submodules,
|
|
371
371
|
};
|
|
372
372
|
}
|
|
373
|
-
function
|
|
373
|
+
function diffPeerResponse(diff) {
|
|
374
374
|
return {
|
|
375
375
|
...(diff.path === undefined ? {} : { path: diff.path }),
|
|
376
376
|
staged: diff.staged,
|
|
@@ -12,10 +12,13 @@ const GIT_LOCAL_ENV_VARS = Object.freeze([
|
|
|
12
12
|
"GIT_WORK_TREE",
|
|
13
13
|
]);
|
|
14
14
|
const plugin = {
|
|
15
|
-
apiVersion:
|
|
15
|
+
apiVersion: 3,
|
|
16
16
|
name: "Git",
|
|
17
17
|
activate(context) {
|
|
18
|
-
return {
|
|
18
|
+
return {
|
|
19
|
+
workspaceProvider: createGitWorkspaceProvider(context),
|
|
20
|
+
peer: { request: (request) => requestGitBackend(context, request) },
|
|
21
|
+
};
|
|
19
22
|
},
|
|
20
23
|
};
|
|
21
24
|
export default plugin;
|
|
@@ -80,7 +83,6 @@ export function createGitWorkspaceProvider(context) {
|
|
|
80
83
|
};
|
|
81
84
|
});
|
|
82
85
|
},
|
|
83
|
-
request: (request) => requestGitBackend(context, request),
|
|
84
86
|
async prepareRemove({ project, workspace, signal }) {
|
|
85
87
|
const privatePath = gitPrivateWorktreePath(workspace);
|
|
86
88
|
if (resolve(privatePath) !== workspace.path) {
|