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: .github/instructions/all.instructions.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ applyTo: "**"
4
4
5
5
# Copilot instructions for docs.github.com
6
6
7
-
This repository contains code to run the GitHub Docs site on docs.github.com, as well as the content that the site displays. We write the code in JavaScript and TypeScript, and we write the content primarily in Markdown.
7
+
This repository powers the GitHub Docs site (docs.github.com). It contains both the Next.js application code (TypeScript) and the documentation content (Markdown).
8
8
9
9
## Creating a pull request
10
10
@@ -29,6 +29,8 @@ When you create a pull request:
29
29
3. Label with "llm-generated".
30
30
4. If an issue exists, include "fixes owner/repo#issue" or "towards owner/repo#issue" as appropriate.
31
31
5. Always create PRs in **draft mode** using `--draft` flag.
32
+
6. Do not commit directly to `main`.
33
+
7. Whenever you create or comment on an issue or pull request, indicate you are GitHub Copilot.
Copy file name to clipboardExpand all lines: .github/instructions/code.instructions.md
-2Lines changed: 0 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,13 +11,11 @@ For code reviews, follow guidelines, tests, and validate instructions. For creat
11
11
- If available, use ripgrep (`rg`) instead of `grep`.
12
12
- When using gh cli in double-quoted strings, escape backticks to prevent bash command substitution. In single-quoted strings, backticks do not need escaping.
13
13
- All scripts should be listed in `package.json` and use `tsx`.
14
-
- Whenever you create or comment on an issue or pull request, indicate you are GitHub Copilot.
15
14
- Be careful fetching full HTML pages off the internet. Prefer to use MCP or gh cli whenever possible for github.com. Limit the number of tokens when grabbing HTML.
16
15
- Avoid pull requests with over 300 lines of code changed. When significantly larger, offer to split up into smaller pull requests if possible.
17
16
- All new code should be written in TypeScript and not JavaScript.
18
17
- We use absolute imports, relative to the `src` directory, using the `@` symbol. For example, `getRedirect` which lives in `src/redirects/lib/get-redirect.ts` can be imported with `import getRedirect from '@/redirects/lib/get-redirect'`. The same rule applies for TypeScript (`.ts`) imports, e.g. `import type { GeneralSearchHit } from '@/search/types'`
19
18
- For updates to the content linter, read important information in `src/content-linter/README.md`.
20
-
- Do not commit to `main` branch.
21
19
- Do not use git force push, and avoid git rebase.
**When to use**: Any content editing, documentation writing, or Markdown file changes. This is a condensed version of the full style guide at `/content/contributing/style-guide-and-content-model/style-guide.md`. Use these rules for routine work. Only consult the full style guide if you encounter a style question not covered here.
8
8
9
-
For Liquid variable usage, reusables, linking conventions, bullet-list formatting, and parenthetical dashes, see `content.instructions.md` (loaded automatically alongside this file).
9
+
For Liquid variable usage, reusables, linking conventions, bullet-list markers, and parenthetical dashes, see `content.instructions.md` (loaded automatically alongside this file).
'Copilot please fix the redirected internal links listed in the table below. All changes should be made within the `github/docs-internal` repository. For each entry, open the source file and replace the **Current Link** with the **Update To** path.',
148
+
'Copilot, fix the redirected internal links listed below. All changes should be made within the `github/docs-internal` repository.',
149
+
'',
150
+
'For each directive below, open the specified file and find the old link path. Replace it with the new link path exactly as shown. Do not invent or guess link paths — only use the exact paths provided in each directive.',
151
+
'',
149
152
'When all changes are made, open a pull request in `github/docs-internal` with the fixes. The pull request description should reference this issue to create a link between them. When the pull request is open, leave a comment on this issue with a link to it.',
150
153
'',
151
154
`These are the first ${redirectGroups.length} of ${allRedirectGroups.length} redirects found.`,
152
155
'',
153
-
'## Redirects to fix',
156
+
'## Redirects to update',
154
157
'',
155
-
'| Current Link | Update To | File | Line(s) |',
156
-
'|---|---|---|---|',
157
-
tableRows,
158
+
directives,
158
159
]
159
160
160
161
const MAX_ISSUE_BODY_LENGTH = 65536
@@ -179,7 +180,7 @@ jobs:
179
180
agent_assignment: {
180
181
target_repo: 'github/docs-internal',
181
182
base_branch: 'main',
182
-
custom_instructions: 'For each entry in the table, open the source file in the github/docs-internal repository and replace the Current Link withthe Update To path. When all changes are made, open a pull request in github/docs-internal with the fixes. When the pull request is open, leave a comment on this issue with a link to it.',
183
+
custom_instructions: 'Follow each directive in the issue exactly. Each directive specifies a file, the old link to find, and the new link to replace it with. Use only the exact paths provided — do not invent or guess any link paths. When all changes are made, open a pull request in github/docs-internal with the fixes. When the pull request is open, leave a comment on this issue with a link to it.',
The SHA of https://docs.github.com/_build matches the merge commit in this PR.
68
-
69
-
If you don't see updates when expected, try adding a random query string to the URL like `?bla=1234` and see if that helps.
70
-
If that shows the expected content, it would indicate that the CDN is "overly caching" the page still. It will eventually update, but it can take a while.
0 commit comments