Skip to content

Commit 75662bf

Browse files
Merge branch 'main' into patch-1
2 parents 58ba41a + 9af6286 commit 75662bf

2,540 files changed

Lines changed: 1857197 additions & 2893584 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/CODEOWNERS

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,5 @@
66
# Site Policy
77
content/site-policy/ @github/site-policy-admins
88

9-
# Enterprise
10-
data/release-notes/**/*.yml @github/docs-content-enterprise
11-
src/ghes-releases/lib/enterprise-dates.json @github/docs-content-enterprise
12-
139
# Requires review of #actions-oidc-integration, docs-engineering/issues/1506
1410
# content/actions/deployment/security-hardening-your-deployments/** @github/oidc

.github/actions/clone-translations/action.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,56 +11,56 @@ runs:
1111
using: 'composite'
1212
steps:
1313
- name: Clone Spanish
14-
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
14+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
1515
with:
1616
repository: github/docs-internal.es-es
1717
token: ${{ inputs.token }}
1818
path: translations/es-es
1919

2020
- name: Clone Japanese
21-
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
21+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
2222
with:
2323
repository: github/docs-internal.ja-jp
2424
token: ${{ inputs.token }}
2525
path: translations/ja-jp
2626

2727
- name: Clone Portuguese
28-
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
28+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
2929
with:
3030
repository: github/docs-internal.pt-br
3131
token: ${{ inputs.token }}
3232
path: translations/pt-br
3333

3434
- name: Clone Simplified Chinese
35-
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
35+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
3636
with:
3737
repository: github/docs-internal.zh-cn
3838
token: ${{ inputs.token }}
3939
path: translations/zh-cn
4040

4141
- name: Clone Russian
42-
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
42+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
4343
with:
4444
repository: github/docs-internal.ru-ru
4545
token: ${{ inputs.token }}
4646
path: translations/ru-ru
4747

4848
- name: Clone French
49-
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
49+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
5050
with:
5151
repository: github/docs-internal.fr-fr
5252
token: ${{ inputs.token }}
5353
path: translations/fr-fr
5454

5555
- name: Clone Korean
56-
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
56+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
5757
with:
5858
repository: github/docs-internal.ko-kr
5959
token: ${{ inputs.token }}
6060
path: translations/ko-kr
6161

6262
- name: Clone German
63-
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
63+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
6464
with:
6565
repository: github/docs-internal.de-de
6666
token: ${{ inputs.token }}

.github/actions/create-workflow-failure-issue/action.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,5 +89,6 @@ runs:
8989
gh issue create \
9090
--repo "$ISSUE_REPO" \
9191
--label "workflow-failure" \
92+
--label "workflow-generated" \
9293
--title "[Workflow Failure] $WORKFLOW_NAME" \
9394
--body "$body"

.github/actions/get-docs-early-access/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ runs:
1919
run: npm run what-docs-early-access-branch
2020

2121
- name: Clone
22-
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
22+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
2323
with:
2424
repository: github/docs-early-access
2525
token: ${{ inputs.token }}

.github/actions/slack-alert/action.yml

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,28 +2,27 @@ name: Send Slack notification if workflow fails
22
description: Send Slack notification if workflow fails
33

44
inputs:
5-
slack_channel_id:
6-
description: Slack channel ID
7-
required: true
85
slack_token:
96
description: Slack token
107
required: true
8+
slack_channel_id:
9+
description: Slack channel ID. Defaults to the docs-alerts channel (CG5MJHMB2).
10+
default: CG5MJHMB2 # docs-alerts
11+
required: false
1112
message:
1213
description: The message to send to Slack
1314
default: The last '${{ github.workflow }}' run failed. See ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
1415
required: false
15-
color:
16-
description: The color of the Slack message
17-
default: failure
18-
required: false
1916

2017
runs:
2118
using: composite
2219
steps:
2320
- name: Send Slack notification if workflow fails
24-
uses: someimportantcompany/github-actions-slack-message@a975b440de2bcef178d451cc70d4c1161b5a30cd
21+
uses: slackapi/slack-github-action@45a88b9581bfab2566dc881e2cd66d334e621e2c # v3.0.3
2522
with:
26-
channel: ${{ inputs.slack_channel_id }}
27-
bot-token: ${{ inputs.slack_token }}
28-
color: ${{ inputs.color }}
29-
text: ${{ inputs.message }}
23+
method: chat.postMessage
24+
token: ${{ inputs.slack_token }}
25+
errors: true
26+
payload: |
27+
channel: ${{ toJSON(inputs.slack_channel_id) }}
28+
text: ${{ toJSON(inputs.message) }}

.github/copilot-instructions.md

Lines changed: 0 additions & 22 deletions
This file was deleted.

.github/dependabot.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@ updates:
3131
day: tuesday
3232
cooldown:
3333
default-days: 7
34+
groups:
35+
actions:
36+
patterns:
37+
- '*'
3438
ignore:
3539
- dependency-name: '*'
3640
update-types:

.github/instructions/all.instructions.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ applyTo: "**"
44

55
# Copilot instructions for docs.github.com
66

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).
88

99
## Creating a pull request
1010

@@ -29,6 +29,8 @@ When you create a pull request:
2929
3. Label with "llm-generated".
3030
4. If an issue exists, include "fixes owner/repo#issue" or "towards owner/repo#issue" as appropriate.
3131
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.
3234

3335
## Accessing docs.github.com content programmatically
3436

.github/instructions/code.instructions.md

Lines changed: 5 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,23 @@ applyTo: "src/**,.github/**,config/**,.devcontainer/**,**Dockerfile,package*.jso
44

55
# Copilot code instructions for docs.github.com
66

7-
For code reviews, follow guidelines, tests, and validate instructions. For creating or updating pull requests or branches, follow the steps instructions.
7+
For code reviews and for creating or updating pull requests, follow the Guidelines, Tests, and Validate sections below.
88

99
## Guidelines
1010

11+
- Before you make a new branch, make sure you have the latest changes by running `git checkout main && git pull`.
1112
- If available, use ripgrep (`rg`) instead of `grep`.
1213
- When using gh cli in double-quoted strings, escape backticks to prevent bash command substitution. In single-quoted strings, backticks do not need escaping.
1314
- 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.
1515
- 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.
1616
- Avoid pull requests with over 300 lines of code changed. When significantly larger, offer to split up into smaller pull requests if possible.
1717
- All new code should be written in TypeScript and not JavaScript.
1818
- 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'`
1919
- For updates to the content linter, read important information in `src/content-linter/README.md`.
20-
- Do not commit to `main` branch.
2120
- Do not use git force push, and avoid git rebase.
21+
- When reading issues and pull requests, read all comments as well.
22+
- When you are updating an existing pull request, after you commit and push, _concisely_ comment on the pull request that you are GitHub Copilot and what changes you made and why.
23+
- When running in agentic mode, offer the human the option to wait for and review CI checks and automatic Copilot code review comments.
2224

2325
## Tests
2426

@@ -81,30 +83,6 @@ Run the following commands to validate your changes:
8183
- `npm run prettier`
8284
- `npm run lint`: you can include `-- --fix`
8385

84-
## Steps
85-
86-
0. Ask the human if they would like you to follow these steps.
87-
1. If this is new work, make sure you have the latest changes by running `git checkout main && git pull`. If this is existing work, update the branch you are working on with the head branch -- usually `main`.
88-
2. If the human provides a GitHub issue, use MCP or gh cli to read the issue and all comments.
89-
3. Begin by evaluating impact, effort, and estimate non-test lines of code that will change. Ask for more context and examples if needed.
90-
4. If you are running in agentic mode, _stop_ at this point and request approval from the human.
91-
5. If you need to add or change tests, work on tests before implementing.
92-
6. Implement the changes needed. If you are running in agentic mode, _stop_ and ask questions at decision points. Please list the options, pros and cons for each decision needed.
93-
7. Validate your changes before making any commits. See "Validate".
94-
8. Validate that any new or changed tests pass. See "Tests".
95-
9. Validate that these changes meet our guidelines. See "Guidelines".
96-
10. If you are running in agentic mode, _stop_ at this point and request review before continuing. Suggest how the human should review the changes.
97-
11. If a branch and pull request already exist, commit and push, then _concisely_ comment on the pull request that you are GitHub Copilot and what changes you made and why.
98-
12. If this is new work and no pull request exists yet, make a pull request:
99-
- label "llm-generated"
100-
- draft mode
101-
- include "fixes owner/repo#issue" or "towards owner/repo#issue" as appropriate
102-
13. If you are in agentic mode, offer to wait for CI to run and check that it passes. If the human agrees, verify in CI: `sleep 240 && gh pr checks $number`. Address all failures, don't assume they're flakes.
103-
14. If you are in agentic mode, offer to do any or all of:
104-
- mark the pull request as ready,
105-
- assign the issue to the human if it is not already assigned,
106-
- _concisely_ comment on the issue explaining the change, indicating you are GitHub Copilot.
107-
10886
## Logger
10987

11088
Use `createLogger` from `@/observability/logger` instead of `console.log` in server-side code.

.github/instructions/content.instructions.md

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,3 +92,61 @@ Examples:
9292
* ❌ Incorrect: "The cat – which sat on a branch – smiled with a broad grin." (en dash with spaces)
9393
* ❌ Incorrect: "The cat-which sat on a branch-smiled with a broad grin." (hyphen without spaces)
9494
* ❌ Incorrect: "The cat - which sat on a branch - smiled with a broad grin." (hyphen with spaces)
95+
96+
## Versioning
97+
98+
Avoid `{% ifversion fpt %}`, `{% ifversion ghec %}`, and `{% ifversion fpt or ghec %}` in content files whenever possible. Instead of suggesting or adding version-gating within an article:
99+
100+
* Write content that applies to all versions the article is versioned for
101+
* If content is truly version-specific, consider whether it is low-harm to show it to all readers (e.g., an enterprise-only row in a reference table)
102+
* Only use `{% ifversion %}` as a last resort when content would be actively misleading for readers on a different version
103+
104+
**FPT and GHEC content**: When dotcom content applies to both products, version the page for `fpt` and `ghec` in the frontmatter. Do NOT use in-article Liquid versioning. Do NOT suggest adding `{% ifversion fpt or ghec %}` blocks as a fix for content that mentions a dotcom-only feature. Instead, suggest rewriting the content using the alternatives to inline versioning options listed below.
105+
106+
**GHES content**: If versioning is necessary for GitHub Enterprise Server content, use feature-based versioning (FBV). GHES content should rely on feature flags defined in `data/features/` rather than inline `{% ifversion ghes %}` blocks. Feature flags allow centralized control of when content appears for specific GHES releases.
107+
108+
### Alternatives to inline versioning
109+
110+
Before resorting to in-article versioning, first consider whether the content is actually different across versions. Often procedures can be simplified to work at both levels.
111+
112+
Use these strategies instead of `{% ifversion %}`, depending on the level of content:
113+
114+
**At the article level:**
115+
116+
* When the feature is only available in certain products, use the "Who can use this feature?" box to convey that the content of the article applies only to specific products
117+
* When an article only exists because the functionality is only available in older GHES releases (and not on {% data variables.product.prodname_dotcom_the_website %} or newer GHES releases), just remove that article
118+
119+
**At the heading level:**
120+
121+
* Use prose similar to "Who can use this feature?" to convey that the content of a section applies only to specific products
122+
123+
**At the paragraph or sentence level:**
124+
125+
* If you're briefly introducing a feature and then linking to an article, there's no need to specify versioning. Let readers learn availability when they follow the link, via the "Who can use this feature?" box
126+
* When necessary, start sentences with "With {% data variables.product.prodname_ghe_cloud %}...", "On {% data variables.product.prodname_dotcom_the_website %}...", etc.
127+
* End list items with "({% data variables.product.prodname_ghe_cloud %} only)", "({% data variables.product.prodname_dotcom_the_website %} only)", etc.
128+
* Specify if the feature is not available for GHES with "NAME-OF-FEATURE is not available for {% data variables.product.prodname_ghe_server %}", "... (not available in {% data variables.product.prodname_ghe_server %})", etc.
129+
130+
### Example
131+
132+
When documenting a feature that only applies to dotcom (not GHES):
133+
134+
❌ Don't wrap content in version blocks:
135+
136+
```markdown
137+
{% ifversion fpt or ghec %}
138+
139+
## Immutable subject claims
140+
141+
Repositories created after July 15, 2026 now use an immutable default subject format.
142+
143+
{% endif %}
144+
```
145+
146+
✅ Do use prose to indicate availability:
147+
148+
```markdown
149+
## Immutable subject claims
150+
151+
Repositories created after July 15, 2026 now use an immutable default subject format. This rollout does not include {% data variables.product.prodname_ghe_server %}.
152+
```

0 commit comments

Comments
 (0)