Skip to content

Commit 0c6d825

Browse files
Updates terminology and adds telemetry
1 parent 1b59716 commit 0c6d825

File tree

6 files changed

+498
-187
lines changed

6 files changed

+498
-187
lines changed

contributions.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@
312312
"commandPalette": "gitlens:enabled && !gitlens:untrusted && gitlens:gk:organization:ai:enabled"
313313
},
314314
"gitlens.ai.mcp.install": {
315-
"label": "Install MCP Server",
315+
"label": "Install GitKraken MCP Server",
316316
"commandPalette": "gitlens:enabled && !gitlens:untrusted && gitlens:gk:organization:ai:enabled"
317317
},
318318
"gitlens.ai.rebaseOntoCommit:graph": {

docs/telemetry-events.md

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -570,6 +570,40 @@ void
570570
}
571571
```
572572

573+
### cli/install/failed
574+
575+
> Sent when a CLI install attempt fails
576+
577+
```typescript
578+
{
579+
'attempts': number,
580+
'autoInstall': boolean,
581+
'error.message': string
582+
}
583+
```
584+
585+
### cli/install/started
586+
587+
> Sent when a CLI install attempt is started
588+
589+
```typescript
590+
{
591+
'attempts': number,
592+
'autoInstall': boolean
593+
}
594+
```
595+
596+
### cli/install/succeeded
597+
598+
> Sent when a CLI install attempt succeeds
599+
600+
```typescript
601+
{
602+
'attempts': number,
603+
'autoInstall': boolean
604+
}
605+
```
606+
573607
### cloudIntegrations/connected
574608

575609
> Sent when connected to one or more cloud-based integrations from gkdev
@@ -2726,6 +2760,35 @@ void
27262760
}
27272761
```
27282762

2763+
### mcp/setup/completed
2764+
2765+
> Sent when GitKraken MCP setup is completed
2766+
2767+
```typescript
2768+
{
2769+
'requiresUserCompletion': boolean
2770+
}
2771+
```
2772+
2773+
### mcp/setup/failed
2774+
2775+
> Sent when GitKraken MCP setup fails
2776+
2777+
```typescript
2778+
{
2779+
'error.message': string,
2780+
'reason': string
2781+
}
2782+
```
2783+
2784+
### mcp/setup/started
2785+
2786+
> Sent when GitKraken MCP setup is started
2787+
2788+
```typescript
2789+
void
2790+
```
2791+
27292792
### openReviewMode
27302793

27312794
> Sent when a PR review was started in the inspect overview

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6298,7 +6298,7 @@
62986298
},
62996299
{
63006300
"command": "gitlens.ai.mcp.install",
6301-
"title": "Install MCP Server",
6301+
"title": "Install GitKraken MCP Server",
63026302
"category": "GitLens"
63036303
},
63046304
{

src/constants.storage.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,6 @@ export type DeprecatedGlobalStorage = {
6363
};
6464

6565
export type GlobalStorage = {
66-
'ai:mcp:install': string;
67-
'ai:mcp:installPath': string;
6866
avatars: [string, StoredAvatar][];
6967
'confirm:ai:generateCommits': boolean;
7068
'confirm:ai:generateRebase': boolean;
@@ -85,7 +83,9 @@ export type GlobalStorage = {
8583
// Value based on `currentOnboardingVersion` in composer's protocol
8684
'composer:onboarding:dismissed': string;
8785
'composer:onboarding:stepReached': number;
88-
'gk:cli:installedPath': string;
86+
'gk:cli:install': { status: 'attempted' | 'unsupported' | 'completed'; attempts: number };
87+
'gk:cli:corePath': string;
88+
'gk:cli:path': string;
8989
'home:sections:collapsed': string[];
9090
'home:walkthrough:dismissed': boolean;
9191
'launchpad:groups:collapsed': StoredLaunchpadGroup[];

src/constants.telemetry.ts

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,13 @@ export interface TelemetryEvents extends WebviewShowAbortedEvents, WebviewShownE
7979
/** Sent when user opts in to AI All Access */
8080
'aiAllAccess/optedIn': void;
8181

82+
/** Sent when a CLI install attempt is started */
83+
'cli/install/started': CLIInstallStartedEvent;
84+
/** Sent when a CLI install attempt succeeds */
85+
'cli/install/succeeded': CLIInstallSucceededEvent;
86+
/** Sent when a CLI install attempt fails */
87+
'cli/install/failed': CLIInstallFailedEvent;
88+
8289
/** Sent when connecting to one or more cloud-based integrations */
8390
'cloudIntegrations/connecting': CloudIntegrationsConnectingEvent;
8491

@@ -238,6 +245,13 @@ export interface TelemetryEvents extends WebviewShowAbortedEvents, WebviewShownE
238245
/** Sent when a launchpad operation is taking longer than a set timeout to complete */
239246
'launchpad/operation/slow': LaunchpadOperationSlowEvent;
240247

248+
/** Sent when GitKraken MCP setup is started */
249+
'mcp/setup/started': void;
250+
/** Sent when GitKraken MCP setup is completed */
251+
'mcp/setup/completed': MCPSetupCompletedEvent;
252+
/** Sent when GitKraken MCP setup fails */
253+
'mcp/setup/failed': MCPSetupFailedEvent;
254+
241255
/** Sent when a PR review was started in the inspect overview */
242256
openReviewMode: OpenReviewModeEvent;
243257

@@ -472,6 +486,31 @@ export interface AIFeedbackEvent extends AIEventDataBase {
472486
'unhelpful.custom'?: string;
473487
}
474488

489+
export interface CLIInstallStartedEvent {
490+
autoInstall: boolean;
491+
attempts: number;
492+
}
493+
494+
export interface CLIInstallSucceededEvent {
495+
autoInstall: boolean;
496+
attempts: number;
497+
}
498+
499+
export interface CLIInstallFailedEvent {
500+
autoInstall: boolean;
501+
attempts: number;
502+
'error.message'?: string;
503+
}
504+
505+
export interface MCPSetupCompletedEvent {
506+
requiresUserCompletion: boolean;
507+
}
508+
509+
export interface MCPSetupFailedEvent {
510+
reason: string;
511+
'error.message'?: string;
512+
}
513+
475514
interface CloudIntegrationsConnectingEvent {
476515
'integration.ids': string | undefined;
477516
}

0 commit comments

Comments
 (0)