You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/copilot/concepts/response-customization.md
+48Lines changed: 48 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,6 +40,11 @@ contentType: concepts
40
40
> [!NOTE] This version of this article is about custom instructions in Xcode. Click the tabs above for other environments. <!-- markdownlint-disable-line MD027 -->
41
41
{% endxcode %}
42
42
43
+
{% eclipse %}
44
+
45
+
> [!NOTE] This version of this article is about custom instructions in Eclipse. Click the tabs above for other environments. <!-- markdownlint-disable-line MD027 -->
46
+
{% endeclipse %}
47
+
43
48
## About customizing {% data variables.copilot.copilot_chat %} responses
44
49
45
50
{% webui %}
@@ -95,6 +100,17 @@ While custom instructions help to add codebase-wide context to each AI workflow,
95
100
96
101
{% endxcode %}
97
102
103
+
{% eclipse %}
104
+
105
+
{% data variables.product.prodname_copilot %} can provide chat responses that are tailored to the way your team works, the tools you use, or the specifics of your project, if you provide it with enough context to do so. Instead of repeatedly adding this contextual detail to your chat questions, you can create a custom instructions file in your repository that automatically adds this information for you. The additional information is not displayed in the chat, but is available to {% data variables.product.prodname_copilot_short %} to allow it to generate higher quality responses.
106
+
107
+
There are two types of repository custom instructions you can use to provide context and instructions to {% data variables.copilot.copilot_chat_short %} in Eclipse:
108
+
109
+
***Workspace custom instructions** which apply to all projects in a workspace, and allow you to specify workspace-wide instructions and preferences, in a single file.
110
+
***Project custom instructions** which apply to a specific project.
111
+
112
+
{% endeclipse %}
113
+
98
114
{% webui %}
99
115
100
116
## Using custom instructions
@@ -243,6 +259,26 @@ Common use cases include:
243
259
244
260
{% endxcode %}
245
261
262
+
{% eclipse %}
263
+
264
+
## About repository custom instructions
265
+
266
+
**Workspace custom instructions** apply to all projects in a workspace, and allow you to specify workspace-wide instructions and preferences. You can use workspace custom instructions to provide context and instructions to {% data variables.copilot.copilot_chat_short %} in Eclipse.
267
+
268
+
**Project custom instructions** consist of a single file, `.github/copilot-instructions.md`, that you create in a project. The instructions you add to the file should be short, self-contained statements that add context or relevant information to supplement chat questions.
269
+
270
+
Common use cases include:
271
+
272
+
***Test generation.** Create instructions for test generation, such as specifying the use of a certain test framework.
273
+
***Code review.** Specify instructions for reviewing code, such as telling a reviewer to look for a specific error in the code.
274
+
***Commit message generation.** Write instructions for generating commit messages, such as format or the type of information to include.
275
+
276
+
### Example
277
+
278
+
{% data reusables.copilot.repository-custom-instructions-example %}
279
+
280
+
{% endeclipse %}
281
+
246
282
## Writing effective custom instructions
247
283
248
284
The instructions you add should ideally be short, self-contained statements provide {% data variables.product.prodname_copilot_short %} with relevant information to help it work.
@@ -292,3 +328,15 @@ Answer all questions in less than 1000 characters, and words of no more than 12
Copy file name to clipboardExpand all lines: content/copilot/how-tos/configure-custom-instructions/add-repository-instructions.md
+39Lines changed: 39 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -44,6 +44,14 @@ This version of this article is for using repository custom instructions in Xcod
44
44
45
45
{% endxcode %}
46
46
47
+
{% eclipse %}
48
+
49
+
> [!NOTE] This feature is currently in {% data variables.release-phases.public_preview %} and is subject to change.
50
+
51
+
This version of this article is for using repository custom instructions in Eclipse. Click the tabs above for instructions on using custom instructions in other environments.
52
+
53
+
{% endeclipse %}
54
+
47
55
## About repository custom instructions for {% data variables.product.prodname_copilot_short %}
48
56
49
57
Repository custom instructions let you provide {% data variables.product.prodname_copilot_short %} with repository-specific guidance and preferences.
@@ -84,6 +92,12 @@ Repository custom instructions let you provide {% data variables.product.prodnam
84
92
85
93
{% endxcode %}
86
94
95
+
{% eclipse %}
96
+
97
+
* The latest version of the {% data variables.product.prodname_copilot_short %} extension must be installed in Eclipse.
98
+
99
+
{% endeclipse %}
100
+
87
101
## Creating a repository custom instructions file
88
102
89
103
{% jetbrains %}
@@ -143,6 +157,31 @@ Whitespace between instructions is ignored, so the instructions can be written a
143
157
144
158
{% endxcode %}
145
159
160
+
{% eclipse %}
161
+
162
+
Eclipse supports two types of repository custom instructions: workspace and project custom instructions.
163
+
164
+
To create a workspace custom instructions file, you can use the {% data variables.product.prodname_copilot_short %} settings page. To create a project custom instructions file, you can create the file manually in the project directory.
165
+
166
+
Whitespace between instructions is ignored, so the instructions can be written as a single paragraph, each on a new line, or separated by blank lines for legibility.
167
+
168
+
### Creating a workspace custom instructions file
169
+
170
+
1. To open the {% data variables.copilot.copilot_chat_short %} panel, click the {% data variables.product.prodname_copilot_short %} icon ({% octicon "copilot" aria-hidden="true" aria-label="copilot" %}) in the status bar at the bottom of Eclipse.
171
+
1. From the menu, select "Edit preferences".
172
+
1. In the left pane, expand {% data variables.product.prodname_copilot %} and click **Custom Instructions**.
173
+
1. Select **Enable workspace instructions**.
174
+
1. In the "Workspace" section, under "Set custom instructions to guide {% data variables.product.prodname_copilot_short %}'s code suggestions in this workspace", add natural language instructions to the file, in Markdown format.
175
+
176
+
### Creating a project custom instructions file
177
+
178
+
1. In the root of your project directory, create a file named `.github/copilot-instructions.md`.
179
+
1. Add your custom instructions in natural language, using Markdown format.
180
+
181
+
Once saved, these instructions will apply to the current project in Eclipse that you open with {% data variables.product.prodname_copilot_short %} enabled.
182
+
183
+
{% endeclipse %}
184
+
146
185
{% vscode %}
147
186
148
187
{% data variables.product.prodname_vscode_shortname %} supports either:
Repository custom instructions are currently supported for:
2
2
***{% data variables.copilot.copilot_chat_short %}** in {% data variables.product.prodname_vscode_shortname %}
3
3
***{% data variables.copilot.copilot_coding_agent %}**
4
-
***{% data variables.copilot.copilot_chat_short %}** in {% data variables.product.prodname_vs %}, JetBrains IDEs, Xcode, and on the {% data variables.product.github %} website (`copilot-instructions.md` file only)
4
+
***{% data variables.copilot.copilot_chat_short %}** in {% data variables.product.prodname_vs %}, JetBrains IDEs, Xcode, Eclipse, and on the {% data variables.product.github %} website (`copilot-instructions.md` file only)
5
5
***{% data variables.copilot.copilot_code-review_short %}** (`copilot-instructions.md` file only)
0 commit comments