Skip to content

Commit 0b1ff65

Browse files
Merge branch 'main' into bugFix
2 parents e62b380 + e977429 commit 0b1ff65

14 files changed

Lines changed: 211 additions & 10 deletions

File tree

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060

6161
// Lifecycle commands
6262
// Install dependencies then install Copilot CLI
63-
"onCreateCommand": "npm ci && npm config set \"//npm.pkg.github.com/:_authToken=$GITHUB_TOKEN\" && npm config set \"@github:registry=https://npm.pkg.github.com/\" && npm install -g @github/copilot",
63+
"onCreateCommand": "npm ci && npm install -g @github/copilot@prerelease",
6464
// Start a web server and keep it running
6565
"postStartCommand": "nohup bash -c 'npm start &'",
6666
// Set port 4000 to be public

.github/workflows/generate-code-scanning-query-lists.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -153,8 +153,10 @@ jobs:
153153
--title "Update CodeQL query tables" \
154154
--repo github/docs-internal \
155155
--label "codeql-query-tables,skip FR board,ready-for-doc-review,workflow-generated" \
156-
--body '👋 humans. This PR updates the **CodeQL query table reusables** with the latest changes in preparation for the next **CodeQL CLI** release.
156+
--body '👋 humans. This PR updates the **CodeQL query table reusables** with the latest changes in preparation for the next **CodeQL CLI** release. (Synced from codeql@${{ steps.codeql.outputs.OPENAPI_COMMIT_SHA }})
157157
158-
No action is required from the first responder for the Docs content team. This PR will be reviewed and merged by the Code scanning and GHAS focus team as part of the next release of CodeQL CLI. (Synced from codeql@${{ steps.codeql.outputs.OPENAPI_COMMIT_SHA }})
159158
160-
If CI does not pass or other problems arise, contact #docs-engineering on slack.'
159+
No action is required from the first responder for the Docs content team. This PR is automatically added to the Docs content review board. Any writer can review this by checking that the PR looks sensible. If CI does not pass or other problems arise, contact #docs-engineering on slack.
160+
161+
162+
When the DRI for the CodeQL CLI release is ready to publish, they will ask us to merge this PR in #docs-content.'

content/actions/reference/runners/self-hosted-runners.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ If you disable automatic updates, you will be required to update your runner ver
121121

122122
For instructions on how to install the latest runner version, see the installation instructions for [the latest release](https://github.com/actions/runner/releases).
123123

124-
>[!WARNING] Any updates released for the software, including major, minor or patch releases, are considered as an available update. If you do not perform a software update within 30 days, the {% data variables.product.prodname_actions %} service will not queue jobs to your runner. In addition, if a critical security update is required, the {% data variables.product.prodname_actions %} service will not queue jobs to your runner until it has been updated.
124+
{% data reusables.actions.self-hosted-runner-update-warning %}
125125

126126
### Webhooks for autoscaling
127127

content/actions/tutorials/use-actions-runner-controller/troubleshoot.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,14 @@ A `401 Unauthorized` error when attempting to obtain an access token for a {% da
157157

158158
{% data reusables.actions.self-hosted-runner-group-limit %}
159159

160+
## Runner updates
161+
162+
{% data reusables.actions.self-hosted-runner-update-warning %}
163+
164+
Validate that your runner software version and/or custom runner image(s) in use are running the latest version.
165+
166+
For more information, see [AUTOTITLE](/actions/reference/runners/self-hosted-runners).
167+
160168
## Legal notice
161169

162170
{% data reusables.actions.actions-runner-controller-legal-notice %}

content/codespaces/setting-your-user-preferences/setting-your-default-editor-for-github-codespaces.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ If you want to use {% data variables.product.prodname_vscode %} as your default
3131

3232
* {% data reusables.codespaces.application-installed-locally %}<br><br>
3333

34-
* If you choose **{% data variables.product.prodname_vscode %}**, {% data variables.product.prodname_github_codespaces %} will automatically open in the desktop application when you next create or open a codespace.
34+
* If you choose **{% data variables.product.prodname_vscode %}** (web client), {% data variables.product.prodname_github_codespaces %} will automatically open in the desktop application when you next create or open a codespace.
3535

3636
You may need to allow access to both your browser and {% data variables.product.prodname_vscode %} for it to open successfully.<br><br>
3737

content/copilot/how-tos/use-copilot-for-common-tasks/use-copilot-to-create-issues.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ You can create issues from {% data variables.copilot.copilot_chat_short %}'s imm
3737
* {% prompt %}In OWNER/REPOSITORY, create a feature request to add fuzzy matching to search.{% endprompt %}
3838
* {% prompt %}Log a bug for a 500 error. This happens consistently when I try to log into the site.{% endprompt %}
3939
* {% prompt %}Create a task to change the application logo background to red and add the label "needs design review".{% endprompt %}
40+
* {% prompt %}In octo-org/octo-repo, create an issue and add relevant code snippets to improve the API response format.{% endprompt %}
4041

4142
> [!NOTE] You can only use {% data variables.product.prodname_copilot_short %} to create issues in repositories where you already have permission to create issues. This feature doesn't change your access or bypass repository permissions.
4243

content/copilot/reference/ai-models/supported-models.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ The following table shows which models are available in each client.
7878
| {% data variables.copilot.copilot_gpt_5 %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} |
7979
| {% data variables.copilot.copilot_o3 %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "x" aria-label="Not included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} |
8080
| {% data variables.copilot.copilot_o4_mini %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "x" aria-label="Not included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} |
81-
| {% data variables.copilot.copilot_claude_sonnet_45 %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "x" aria-label="Not included" %} | {% octicon "x" aria-label="Not included" %} | {% octicon "x" aria-label="Not included" %} | {% octicon "x" aria-label="Not included" %} |
81+
| {% data variables.copilot.copilot_claude_sonnet_45 %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} |
8282
| {% data variables.copilot.copilot_claude_opus_41 %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} |
8383
| {% data variables.copilot.copilot_claude_opus %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} |
8484
| {% data variables.copilot.copilot_claude_sonnet_35 %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} | {% octicon "check" aria-label="Included" %} |
Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
---
2+
title: Creating issues
3+
shortTitle: Create issues
4+
intro: '{% data variables.copilot.copilot_chat_short %} can help you quickly create issues without filling out every field manually.'
5+
versions:
6+
feature: copilot
7+
complexity:
8+
- Simple
9+
octicon: copilot
10+
category:
11+
- Document code
12+
topics:
13+
- Copilot
14+
contentType: tutorials
15+
---
16+
17+
Creating issues manually can be time-consuming. {% data variables.copilot.copilot_chat_short %} lets you create issues from natural language, and automatically fills in the title, body, labels, and other metadata based on your prompt.
18+
19+
## Example scenario
20+
21+
You're working on an API service and need to add server-side validation to the `createUser` endpoint. Instead of drafting the issue manually, you use {% data variables.copilot.copilot_chat_short %} to generate a detailed issue description that includes an example implementation of the validation middleware.
22+
23+
The following snippet shows the current implementation of the `createUser` route, before validation is added:
24+
25+
```javascript
26+
// Route
27+
app.post('/users', validateCreateUser, (req, res) => {
28+
const { username, email } = req.body;
29+
// Simulate user creation
30+
res.status(201).json({ message: 'User created', user: { username, email } });
31+
});
32+
```
33+
34+
## Example prompt
35+
36+
`In octo-org/octo-repo, create an issue to add server-side validation for the createUser API endpoint. Include an example of how to validate the request body using an existing middleware pattern. Label it with "backend" and "enhancement".`
37+
38+
## Example response
39+
40+
{% data reusables.copilot.example-prompts.response-is-an-example %}
41+
42+
When you submit the prompt, {% data variables.copilot.copilot_chat_short %} generates a draft issue based on your description and includes a code snippet. You can review and edit the draft before creating the issue.
43+
44+
```markdown
45+
## Problem
46+
The `createUser` API endpoint currently lacks robust server-side validation for incoming requests. To ensure data integrity and security, we should validate the request body before proceeding with user creation.
47+
48+
**Current API endpoint:**
49+
// Route
50+
app.post('/users', validateCreateUser, (req, res) => {
51+
const { username, email } = req.body;
52+
// Simulate user creation
53+
res.status(201).json({ message: 'User created', user: { username, email } });
54+
});
55+
56+
## Proposal
57+
- Add server-side validation for the request body using the existing middleware pattern.
58+
- Ensure required fields (`username`, `email`) are present and valid.
59+
- Return a 400 Bad Request response if validation fails.
60+
61+
**Example (middleware pattern):**
62+
function validateCreateUser(req, res, next) {
63+
const { username, email } = req.body;
64+
if (!username || !email) {
65+
return res.status(400).json({ error: 'Username and email are required.' });
66+
}
67+
// Additional validation logic here
68+
next();
69+
}
70+
71+
app.post('/users', validateCreateUser, (req, res) => {
72+
// ...
73+
});
74+
75+
76+
## Acceptance Criteria
77+
- Server-side validation middleware is added to the `createUser` endpoint.
78+
- Request body is properly validated.
79+
- Appropriate error responses are returned for invalid requests.
80+
```

content/copilot/tutorials/copilot-chat-cookbook/document-code/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ versions:
1010
topics:
1111
- Copilot
1212
children:
13+
- /creating-issues
1314
- /document-legacy-code
1415
- /explain-legacy-code
1516
- /explain-complex-logic

content/copilot/tutorials/plan-a-project.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,12 +88,12 @@ After you finish generating the issue tree you may notice that {% data variables
8888
1. Start with the newly generated issue such as "Task: Create placeholder pages for main routes".
8989

9090
Prompt {% data variables.product.prodname_copilot_short %} with:
91-
```Can you improve the description for “Task: Create placeholder pages for main routes”? Please provide a detailed technical summary, list the main routes to be included, outline the steps for implementation, and specify what should be delivered for this task.```
91+
```Can you improve the description for “Task: Create placeholder pages for main routes”? Please provide a detailed technical summary, list the main routes to be included, outline the steps for implementation, and specify what should be delivered for this task. Please add any relevant code snippets.```
9292

9393
1. {% data variables.product.prodname_copilot_short %} will generate a new version of the draft issue "Task: Create placeholder pages for main routes."
9494

9595
At the top-left of the issue, click the versioning drop-down and select **Version 2** to review the new changes.
96-
1. Review and decide whether to keep {% data variables.product.prodname_copilot_short %}’s revised version, edit further, or prompt again for more detail.
96+
1. Review and decide whether to keep {% data variables.product.prodname_copilot_short %}’s revised version, edit further, or prompt again for more detail. {% data variables.product.prodname_copilot_short %} can add code snippets into the draft to improve clarity and provide immediate context for these issues.
9797
1. Repeat this process for other issues in the epic, refining descriptions and breaking down tasks as needed.
9898
1. Once you’re satisfied with the issue descriptions, click **Create all** to create the issues in your repository.
9999

0 commit comments

Comments
 (0)