Skip to content

Commit 16f63f5

Browse files
Merge branch 'main' into patch-1
2 parents 0152f9c + e8a6382 commit 16f63f5

2,073 files changed

Lines changed: 769436 additions & 2510078 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/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: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,11 @@ For code reviews, follow guidelines, tests, and validate instructions. For creat
1111
- If available, use ripgrep (`rg`) instead of `grep`.
1212
- When using gh cli in double-quoted strings, escape backticks to prevent bash command substitution. In single-quoted strings, backticks do not need escaping.
1313
- 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.
1514
- 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.
1615
- Avoid pull requests with over 300 lines of code changed. When significantly larger, offer to split up into smaller pull requests if possible.
1716
- All new code should be written in TypeScript and not JavaScript.
1817
- 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'`
1918
- For updates to the content linter, read important information in `src/content-linter/README.md`.
20-
- Do not commit to `main` branch.
2119
- Do not use git force push, and avoid git rebase.
2220

2321
## Tests

.github/instructions/style-guide-summary.instructions.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ applyTo: "content/**,data/**,**/*.md"
66

77
**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.
88

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

1111
## Core principles
1212

@@ -52,15 +52,13 @@ For Liquid variable usage, reusables, linking conventions, bullet-list formattin
5252

5353
## Links
5454

55-
* Use `[AUTOTITLE](/path/to/article)` for all internal links. Never hardcode article titles in link text.
5655
* Introduce links with "For more information, see" or "See" when context is clear.
5756
* Do not use inline links where words within a sentence are hyperlinked without additional context.
5857
* Do not include punctuation inside a hyperlink.
5958
* Do not repeat the same link more than once in the same article.
6059

6160
## Lists
6261

63-
* Use `*` (asterisks) for unordered lists, never `-` (hyphens).
6462
* Capitalize the first letter of each list item.
6563
* Use periods only if the item is a complete sentence.
6664
* Introduce lists with a descriptive sentence, not vague phrases like "the following" in isolation.
@@ -83,9 +81,8 @@ For Liquid variable usage, reusables, linking conventions, bullet-list formattin
8381
* Use full words for Apple modifier keys (`Command`, `Option`, `Control`), not symbols.
8482
* Capitalize letter keys.
8583

86-
## Product names and variables
84+
## Product names
8785

88-
* Always use Liquid variables for product names—never hardcode them. Check `data/variables/product.yml` and `data/variables/copilot.yml`.
8986
* Product names are always singular (for example, "GitHub Actions helps" not "help").
9087

9188
## Word choice

.github/workflows/benchmark-pages.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,6 @@ jobs:
161161
- uses: ./.github/actions/slack-alert
162162
if: ${{ failure() && github.event_name != 'workflow_dispatch' }}
163163
with:
164-
slack_channel_id: ${{ secrets.DOCS_ALERTS_SLACK_CHANNEL_ID }}
165164
slack_token: ${{ secrets.SLACK_DOCS_BOT_TOKEN }}
166165

167166
- uses: ./.github/actions/create-workflow-failure-issue

.github/workflows/changelog-agent.yml

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -112,10 +112,12 @@ jobs:
112112
if: steps.check_team.outputs.is_team_member == 'true'
113113
id: extract_issue
114114
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
115+
env:
116+
PR_BODY: ${{ steps.resolve_pr.outputs.pr_body }}
115117
with:
116118
github-token: ${{ secrets.DOCS_BOT_PAT_BASE }}
117119
script: |
118-
const body = `${{ steps.resolve_pr.outputs.pr_body }}`;
120+
const body = process.env.PR_BODY || '';
119121
120122
// Match closing keywords followed by docs-content issue references.
121123
// Supports: closes github/docs-content#123, fixes https://github.com/github/docs-content/issues/123
@@ -224,6 +226,10 @@ jobs:
224226
if: steps.check_parent.outputs.has_parent == 'true'
225227
id: gather_context
226228
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
229+
env:
230+
PR_TITLE: ${{ steps.resolve_pr.outputs.pr_title }}
231+
PR_BODY: ${{ steps.resolve_pr.outputs.pr_body }}
232+
PR_URL: ${{ steps.resolve_pr.outputs.pr_url }}
227233
with:
228234
github-token: ${{ secrets.DOCS_BOT_PAT_BASE }}
229235
script: |
@@ -254,9 +260,9 @@ jobs:
254260
const changedFiles = files.map(f => f.filename);
255261
256262
core.setOutput('pr_author', prAuthor);
257-
core.setOutput('pr_title', '${{ steps.resolve_pr.outputs.pr_title }}');
258-
core.setOutput('pr_body', `${{ steps.resolve_pr.outputs.pr_body }}`);
259-
core.setOutput('pr_url', '${{ steps.resolve_pr.outputs.pr_url }}');
263+
core.setOutput('pr_title', process.env.PR_TITLE || '');
264+
core.setOutput('pr_body', process.env.PR_BODY || '');
265+
core.setOutput('pr_url', process.env.PR_URL || '');
260266
core.setOutput('pr_number', prNumber.toString());
261267
core.setOutput('approved_reviewers', approvedReviewers.join(','));
262268
core.setOutput('changed_files', changedFiles.join('\n'));
@@ -421,14 +427,19 @@ jobs:
421427
- name: Dry run summary
422428
if: steps.generate_draft.outputs.response != '' && inputs.dry_run == true
423429
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
430+
env:
431+
PR_AUTHOR: ${{ steps.gather_context.outputs.pr_author }}
432+
PR_URL: ${{ steps.gather_context.outputs.pr_url }}
433+
PARENT_TITLE: ${{ steps.check_parent.outputs.parent_title }}
434+
DRAFT: ${{ steps.generate_draft.outputs.response }}
424435
with:
425436
script: |
426437
core.info('=== DRY RUN — no PR will be created, no Slack DM sent ===');
427-
core.info(`PR author: ${{ steps.gather_context.outputs.pr_author }}`);
428-
core.info(`Source PR: ${{ steps.gather_context.outputs.pr_url }}`);
429-
core.info(`Parent issue: ${{ steps.check_parent.outputs.parent_title }}`);
438+
core.info(`PR author: ${process.env.PR_AUTHOR || ''}`);
439+
core.info(`Source PR: ${process.env.PR_URL || ''}`);
440+
core.info(`Parent issue: ${process.env.PARENT_TITLE || ''}`);
430441
core.info('--- Generated changelog draft ---');
431-
core.info(`${{ steps.generate_draft.outputs.response }}`);
442+
core.info((process.env.DRAFT || '').replace(/^::/gm, ': :'));
432443
core.info('--- End of draft ---');
433444
434445
- name: Create changelog PR in docs-content

.github/workflows/close-on-invalid-label.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,5 +44,4 @@ jobs:
4444
- uses: ./.github/actions/slack-alert
4545
if: ${{ failure() && github.event_name != 'pull_request_target' }}
4646
with:
47-
slack_channel_id: ${{ secrets.DOCS_ALERTS_SLACK_CHANNEL_ID }}
4847
slack_token: ${{ secrets.SLACK_DOCS_BOT_TOKEN }}

.github/workflows/codeql.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ jobs:
3939
- uses: ./.github/actions/slack-alert
4040
if: ${{ failure() && github.event_name != 'pull_request' }}
4141
with:
42-
slack_channel_id: ${{ secrets.DOCS_ALERTS_SLACK_CHANNEL_ID }}
4342
slack_token: ${{ secrets.SLACK_DOCS_BOT_TOKEN }}
4443

4544
- uses: ./.github/actions/create-workflow-failure-issue

0 commit comments

Comments
 (0)