README + reduce required VS Code version for companion extension (#5719)

This commit is contained in:
Shreya Keshive
2025-08-07 17:25:06 -04:00
committed by GitHub
parent 4d4eacfc40
commit f1663d9615
5 changed files with 20 additions and 20 deletions

View File

@@ -8,11 +8,15 @@ The Gemini CLI Companion extension seamlessly integrates [Gemini CLI](https://gi
- Selection Context: Gemini CLI can easily access your cursor's position and selected text within the editor, giving it valuable context directly from your current work.
- Native Diffing: Seamlessly view, modify, and accept code changes suggested by Gemini CLI directly within the editor.
- Launch Gemini CLI: Quickly start a new Gemini CLI session from the Command Palette (Cmd+Shift+P or Ctrl+Shift+P) by running the "Gemini CLI: Run" command.
# Requirements
To use this extension, you'll need:
- VS Code version 1.101.0 or newer
- VS Code version 1.99.0 or newer
- Gemini CLI (installed separately) running within the VS Code integrated terminal
# Terms of Service and Privacy Notice

View File

@@ -11,7 +11,7 @@
"directory": "packages/vscode-ide-companion"
},
"engines": {
"vscode": "^1.101.0"
"vscode": "^1.99.0"
},
"license": "LICENSE",
"preview": true,
@@ -113,7 +113,7 @@
"@types/cors": "^2.8.19",
"@types/express": "^5.0.3",
"@types/node": "20.x",
"@types/vscode": "^1.101.0",
"@types/vscode": "^1.99.0",
"@typescript-eslint/eslint-plugin": "^8.31.1",
"@typescript-eslint/parser": "^8.31.1",
"esbuild": "^0.25.3",

View File

@@ -56,7 +56,7 @@ export class DiffManager {
private diffDocuments = new Map<string, DiffInfo>();
constructor(
private readonly logger: vscode.OutputChannel,
private readonly log: (message: string) => void,
private readonly diffContentProvider: DiffContentProvider,
) {}
@@ -151,9 +151,7 @@ export class DiffManager {
async acceptDiff(rightDocUri: vscode.Uri) {
const diffInfo = this.diffDocuments.get(rightDocUri.toString());
if (!diffInfo) {
this.logger.appendLine(
`No diff info found for ${rightDocUri.toString()}`,
);
this.log(`No diff info found for ${rightDocUri.toString()}`);
return;
}
@@ -179,9 +177,7 @@ export class DiffManager {
async cancelDiff(rightDocUri: vscode.Uri) {
const diffInfo = this.diffDocuments.get(rightDocUri.toString());
if (!diffInfo) {
this.logger.appendLine(
`No diff info found for ${rightDocUri.toString()}`,
);
this.log(`No diff info found for ${rightDocUri.toString()}`);
// Even if we don't have diff info, we should still close the editor.
await this.closeDiffEditor(rightDocUri);
return;

View File

@@ -42,7 +42,7 @@ export async function activate(context: vscode.ExtensionContext) {
updateWorkspacePath(context);
const diffContentProvider = new DiffContentProvider();
const diffManager = new DiffManager(logger, diffContentProvider);
const diffManager = new DiffManager(log, diffContentProvider);
context.subscriptions.push(
vscode.workspace.onDidCloseTextDocument((doc) => {