From fa71349bdc437b25bf2cc31e2d99e798e6d88a2c Mon Sep 17 00:00:00 2001 From: Chris Burns <29541485+ChrisJBurns@users.noreply.github.com> Date: Mon, 17 Feb 2025 17:49:26 +0000 Subject: [PATCH 1/4] fix: adds note for copilot docs If you have a file open, when running `codegate version`, you get a response based on the file and not the codegate version itself. I've added a note to inform users that they close all files before running the command. Outside of this PR, we may want to decide if this is desired functionality by Copilot or Codegate and if the version should be returned regardless if a file is currently open or not. --- docs/integrations/copilot.mdx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/integrations/copilot.mdx b/docs/integrations/copilot.mdx index 8fd638f..14fd730 100644 --- a/docs/integrations/copilot.mdx +++ b/docs/integrations/copilot.mdx @@ -234,6 +234,12 @@ To verify that you've successfully connected Copilot to CodeGate, open the Copilot chat and type `codegate version`. You should receive a response like "CodeGate version 0.1.13". +:::note + +Make sure you have no open files when running the `codegate version` command, otherwise Copilot will make comments based on the file you have open. + +::: + Date: Tue, 18 Feb 2025 18:49:48 +0000 Subject: [PATCH 2/4] amend wording Co-authored-by: Dan Barr --- docs/integrations/copilot.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/integrations/copilot.mdx b/docs/integrations/copilot.mdx index 14fd730..573c62c 100644 --- a/docs/integrations/copilot.mdx +++ b/docs/integrations/copilot.mdx @@ -231,8 +231,8 @@ Append the following settings to your configuration: ## Verify configuration To verify that you've successfully connected Copilot to CodeGate, open the -Copilot chat and type `codegate version`. You should receive a response like -"CodeGate version 0.1.13". +Copilot Chat (not Copilot Edits) and type `codegate version`. You should receive +a response like "CodeGate version 0.1.13". :::note From 7bb41beab8905ae5549baafed078119b4921b293 Mon Sep 17 00:00:00 2001 From: Chris Burns <29541485+ChrisJBurns@users.noreply.github.com> Date: Tue, 18 Feb 2025 18:50:47 +0000 Subject: [PATCH 3/4] amends note wording Co-authored-by: Dan Barr --- docs/integrations/copilot.mdx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/integrations/copilot.mdx b/docs/integrations/copilot.mdx index 573c62c..fbf5664 100644 --- a/docs/integrations/copilot.mdx +++ b/docs/integrations/copilot.mdx @@ -236,7 +236,11 @@ a response like "CodeGate version 0.1.13". :::note -Make sure you have no open files when running the `codegate version` command, otherwise Copilot will make comments based on the file you have open. +There is a [known issue](https://github.com/stacklok/codegate/issues/1061) with +`codegate` commands in Copilot chat if you have a file included in the context. +Close all open files or use the eye icon in the chat input to disable the +current file context, otherwise Copilot responds based on the file you have open +instead of returning the command result. ::: From ba7af3cd6359e647b85c4b9706f3fbd608438be6 Mon Sep 17 00:00:00 2001 From: ChrisJBurns <29541485+ChrisJBurns@users.noreply.github.com> Date: Tue, 18 Feb 2025 18:52:22 +0000 Subject: [PATCH 4/4] docs: adds note around copilot context bug Signed-off-by: ChrisJBurns <29541485+ChrisJBurns@users.noreply.github.com> --- docs/quickstart-copilot.mdx | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/quickstart-copilot.mdx b/docs/quickstart-copilot.mdx index 361d9a8..ee2a791 100644 --- a/docs/quickstart-copilot.mdx +++ b/docs/quickstart-copilot.mdx @@ -97,6 +97,16 @@ Add the following settings to your configuration: Enter `codegate version` in the Copilot chat to confirm that CodeGate is intercepting Copilot traffic. CodeGate responds with its version number. +:::note + +There is a [known issue](https://github.com/stacklok/codegate/issues/1061) with +`codegate` commands in Copilot chat if you have a file included in the context. +Close all open files or use the eye icon in the chat input to disable the +current file context, otherwise Copilot responds based on the file you have open +instead of returning the command result. + +::: + ## Explore CodeGate's key features To learn more about CodeGate's capabilities, clone the demo repository to a