Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
117 commits
Select commit Hold shift + click to select a range
bda6a3a
Fall back to English for archived GHES links missing the user languag…
heiskr Oct 20, 2026
10a5de1
Clamp the landing article grid page to the available pages (#64049)
heiskr Oct 20, 2026
a1812d8
Keep reusable indentation inside blockquotes and alerts (#64054)
heiskr Oct 20, 2026
d6b534e
Show true and false enum values in parameter tables (#64055)
heiskr Oct 20, 2026
b44743e
Skip non-string carousel entries in the landing carousels lint rule (…
heiskr Oct 20, 2026
81a3901
Skip cross-product children and duplicates in categories.json (#64058)
heiskr Oct 20, 2026
906ebe4
Reset category landing filters when navigating between landings (#64059)
heiskr Oct 20, 2026
89de73e
Bump devcontainers/javascript-node from `5ed0bf1` to `d0445b9` in /.d…
dependabot[bot] Oct 20, 2026
2c7e2cd
Search only visible card text on category landing pages (#64060)
heiskr Oct 20, 2026
5e4c06c
Read all review pages when crediting changelog approvers (#64061)
heiskr Oct 20, 2026
63fb5ee
Search up to 1000 changelog PRs when matching release issues (#64062)
heiskr Oct 20, 2026
f12ceb7
Count Chinese and Japanese words in survey comment rating (#64063)
heiskr Oct 20, 2026
a7d99b4
Include data/reusables in link report codemod commands (#64064)
heiskr Oct 20, 2026
edafeeb
Keep version-pinned links in CodeQL CLI markdown output (#64066)
heiskr Oct 20, 2026
e06ee0f
Keep CodeQL CLI option headings with <name@range> in one code span (#…
heiskr Oct 20, 2026
498f28b
Fail CodeQL push runs on main when analysis fails (#64068)
heiskr Oct 20, 2026
2bf3a88
Skip docs-bot PRs when adding work to the central triage board (#64222)
heiskr Oct 20, 2026
fbeeac3
Match UTM link rewriting on the GitHub hostname (#64225)
heiskr Oct 20, 2026
438e509
Flag indented Liquid versioning lines in list-nested tables (#64217)
heiskr Oct 20, 2026
db0e785
Remove empty .nvmrc and point docs to package.json engines (#64237)
heiskr Oct 20, 2026
9da7b50
Redirect /zh-Hans and /zh-Hant paths to /zh (#64235)
heiskr Oct 20, 2026
8c16f31
Stop double-firing code copy buttons on article pages (#64238)
heiskr Oct 20, 2026
7c8ed51
Remove the no-op Fastly purge from general search indexing (#64239)
heiskr Oct 20, 2026
1054b78
Revert the firewall URLs for package firewall. (#64298)
ahpook Oct 20, 2026
6be4b4f
Pass GITHUB_TOKEN to the weekly external link check (#64236)
heiskr Oct 20, 2026
e7fbabc
Catch missing llms.txt pinned pages in tests and warn when skipped (#…
heiskr Oct 20, 2026
39baf96
Allow inline scripts again on archived Enterprise pages (#64039)
heiskr Oct 20, 2026
f439904
Validate the Copilot auto model selection table against its schema (#…
heiskr Oct 20, 2026
3345e43
Use the full Description paragraph for CodeQL CLI intros (#64065)
heiskr Oct 20, 2026
1a81906
Open the CodeQL query tables PR when a rerun finds an orphan branch (…
heiskr Oct 20, 2026
4dc0b82
Copilot IA: concepts customizations category (#63578)
dihydroJenoxide Oct 20, 2026
16b1221
Sync secret scanning data (#64301)
docs-bot Oct 20, 2026
232c0c7
Stop flagging staff who transfer issues out of github/docs (#64070)
heiskr Oct 20, 2026
a8d2bc7
Escape search-replace rule names in the content linter rules table (#…
heiskr Oct 20, 2026
430616b
Skip first-time contributor lookup for Copilot-authored PRs (#64074)
heiskr Oct 20, 2026
33d911f
Stop Copilot redirect issues from hardcoding version prefixes (#64075)
heiskr Oct 20, 2026
dedbc20
Map legacy Copilot Pro+ CTAs to the pro-plus plan (#64076)
heiskr Oct 20, 2026
d2fee4d
Hide parameter expanders that can never load properties (#64078)
heiskr Oct 20, 2026
b7c789f
Include composite actions in Dependabot github-actions updates (#64079)
heiskr Oct 20, 2026
4fe494c
Use the triggering deploy SHA for production comments (#64080)
heiskr Oct 20, 2026
15536cc
Clarify recovery for compromised personal accounts (#63790)
Copilot Oct 20, 2026
b3a61e5
Stop dev-toc from crashing when the browser opener is missing (#64082)
heiskr Oct 20, 2026
345b919
Skip YAML data violations in disable-rules.ts instead of crashing (#6…
heiskr Oct 20, 2026
374ce6b
Show restore steps in the job summary when fork PR comments fail (#64…
heiskr Oct 20, 2026
ecb2e7d
Send one page event when a navigation cancels another (#64086)
heiskr Oct 20, 2026
d727a9a
Return 404 for WebP asset paths that fail with ENOTDIR or ENAMETOOLON…
heiskr Oct 20, 2026
f5a863e
Limit update-data-and-image-paths default to Early Access files (#64090)
heiskr Oct 20, 2026
e036c2f
Skip empty schema change groups in the GraphQL changelog (#64092)
heiskr Oct 20, 2026
36ac831
Use English heading IDs on translated index pages (#64093)
heiskr Oct 20, 2026
e96bd64
Add GHES troubleshooting article: Pending reboot after a hotpatch (#6…
benwebb-au Oct 20, 2026
a952962
Match early access paths on a directory boundary in path updates (#64…
heiskr Oct 20, 2026
e73055d
Restore GitHub React a11y lint rules lost in flat config (#64095)
heiskr Oct 20, 2026
abb2bbd
Show each broken URL and its status in the external link report (#64096)
heiskr Oct 20, 2026
d7642f4
Match code fence closers by indent relative to the opener in link che…
heiskr Oct 20, 2026
6342885
Stop feature param forwarding from hijacking new-tab and external lin…
heiskr Oct 20, 2026
114e6ed
Point footer Privacy link at the real privacy statement page (#64104)
heiskr Oct 20, 2026
f148430
Check elsif tags for quoted arguments in GHD016 (#64105)
heiskr Oct 20, 2026
1e9286d
Delete GHD022 conditions that name no frontmatter products (#64107)
heiskr Oct 20, 2026
502199a
Auto 30 percent Copilot Max discount (#64072)
dihydroJenoxide Oct 20, 2026
80a6288
Keep earlier branches when a GHD022 elsif covers all versions (#64108)
heiskr Oct 20, 2026
4f2b38f
Use the versioned page title on the GHEC homepage (#64109)
heiskr Oct 20, 2026
3ce1a46
Show release dates for GHES 11.10.340 on the all releases page (#64110)
heiskr Oct 20, 2026
6189093
Add /api/v3 to GHES REST response example URLs (#64111)
heiskr Oct 20, 2026
706add0
Add the 2022-11-28 section to GHES REST breaking changes changelog (#…
heiskr Oct 20, 2026
0120cbe
Remove the extra q= prefix from the github/github link search (#64113)
heiskr Oct 20, 2026
c63704e
Keep glossary term anchors when updating redirected links (#64114)
heiskr Oct 20, 2026
b9d7e3f
Stop GraphQL built-in scalar hrefs from growing on each version (#64115)
heiskr Oct 20, 2026
f2b3306
Repository-level bulk migration from Branch Protections to Rulesets (…
guntrip Oct 20, 2026
5e59e61
Send only interface implementers to GraphQL category pages (#64116)
heiskr Oct 20, 2026
f2016a5
Keep spaces around quoted words in GraphQL descriptions (#64118)
heiskr Oct 20, 2026
96bd30d
Show false and query argument defaults in GraphQL reference Markdown …
heiskr Oct 20, 2026
5d1e70c
Decode percent-encoded hash before focusing the heading (#64121)
heiskr Oct 20, 2026
8661a16
Ignore fenced code when computing heading anchor IDs (#64122)
heiskr Oct 20, 2026
90248f6
Stop GHD010 from exempting hidden pages in content/search-github (#64…
heiskr Oct 20, 2026
0f347f2
Move hovercard keyboard focus to the title when the product is hidden…
heiskr Oct 20, 2026
b6b3bee
Fix homepage review links and removed-file fetch in changes table (#6…
heiskr Oct 20, 2026
e417f7b
Pin GraphQL category item sort to the en locale (#64117)
heiskr Oct 20, 2026
300ada3
Skip plain elsif tags and flag long clauses in GHD020 (#64128)
heiskr Oct 20, 2026
57890be
Ignore unless and for else tags in GHD022 ifversion checks (#64129)
heiskr Oct 20, 2026
1feaf28
Skip URI scheme links in GHD003 and fix its autofix column (#64131)
heiskr Oct 20, 2026
3ac51dd
Check journey guide paths only from the content root (#64132)
heiskr Oct 20, 2026
288c341
Render Liquid in journey track titles on article pages (#64133)
heiskr Oct 20, 2026
752840d
Skip blank labels when labeler action inputs are omitted (#64135)
heiskr Oct 20, 2026
aad96c5
Sort landing article grid titles with the page locale (#64136)
heiskr Oct 20, 2026
346725c
Lint Liquid syntax in journey track timeCommitment (#64134)
heiskr Oct 20, 2026
7338660
Skip template headings when indexing landing pages for search (#64137)
heiskr Oct 20, 2026
d62f6e5
Honor the version cookie on language homepages (#64139)
heiskr Oct 20, 2026
d25a79d
Report link punctuation ranges on the link's own line (#64140)
heiskr Oct 20, 2026
bc08b53
Exit 1 when lint-content gets an unknown --rules name (#64141)
heiskr Oct 20, 2026
66ad319
Report invalid frontmatter YAML instead of crashing the content linte…
heiskr Oct 20, 2026
e770f0f
Lint Copilot matrix-meta.yml against its own data schema (#64144)
heiskr Oct 20, 2026
3258eec
Collapse every extra-space gap in GHD042 liquid tag auto-fix (#64145)
heiskr Oct 20, 2026
94928ac
Print per-rule warning counts for lint-content --summary-by-rule (#64…
heiskr Oct 20, 2026
aff8841
Render llms.txt titles and intros with the fpt version context (#64146)
heiskr Oct 20, 2026
1294c88
Skip lockfile churn detection when a PR is reopened (#64147)
heiskr Oct 20, 2026
388ad51
Keep GitHub alert markers unescaped in markdown output (#64148)
heiskr Oct 20, 2026
767569e
Send raw text and Content-Type in curl examples for text bodies (#64149)
heiskr Oct 20, 2026
c9e7173
Detect Chrome, Firefox, and Edge on iOS and Edge on Android (#64150)
heiskr Oct 20, 2026
d15e022
Fail the SDK docs sync when no Mermaid diagram renders (#64151)
heiskr Oct 20, 2026
8e3a491
Stop counting digits, # and * as emoji in survey comments (#64158)
heiskr Oct 20, 2026
7ec4cbb
Fix move-content workflow path filters so they match real files (#64159)
heiskr Oct 20, 2026
1eeb543
Exempt needs SME items from the inactive stale check (#64162)
heiskr Oct 20, 2026
8538cbb
Run the weekly no-response sweep when the cron actor is a bot (#64164)
heiskr Oct 20, 2026
0cc6c90
Run OpenAPI check workflow when operation helpers change (#64165)
heiskr Oct 20, 2026
1cf84fe
Run orphaned files dry run when its script dependencies change (#64166)
heiskr Oct 20, 2026
48539ed
Skip tests when scanning code for orphaned tables (#64168)
heiskr Oct 20, 2026
a869f00
Close the In this article menu when keyboard focus leaves it (#64169)
heiskr Oct 20, 2026
b6faee7
Stop pagelist redirect loop for percent-encoded @ versions (#64170)
heiskr Oct 20, 2026
098a014
Collapse the faceted search into a single Elasticsearch query (#63007)
Ebonsignori Oct 20, 2026
9e251f3
Strip trailing slashes from move-content path arguments (#64160)
heiskr Oct 20, 2026
9ca2653
Stop /api/pagelist/free-pro-team from redirecting to French (#64171)
heiskr Oct 20, 2026
ecd4d2a
Keep focus on the picker tab when the selected tab is activated (#64172)
heiskr Oct 20, 2026
025d072
Stop verbose general search indexing from crashing after one index (#…
heiskr Oct 20, 2026
424b60f
Show a code example for REST endpoints that only redirect (#64175)
heiskr Oct 20, 2026
150281b
Wrap only the visited image in procedural list steps (#64177)
heiskr Oct 20, 2026
a99e502
Keep the full query string when it contains a second question mark (#…
heiskr Oct 20, 2026
24f0601
Render GHES release notes in English in the article API (#64179)
heiskr Oct 20, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Update ARG and FROM together from the Node devcontainer image tags:
# https://mcr.microsoft.com/en-us/product/devcontainers/javascript-node/tags
ARG VARIANT=dev-24-bookworm
FROM mcr.microsoft.com/devcontainers/javascript-node:dev-24-bookworm@sha256:5ed0bf1411cffe8182ee6808477dd64c969a4ce78fee1b63e6a654d7deff889c
FROM mcr.microsoft.com/devcontainers/javascript-node:dev-24-bookworm@sha256:d0445b9546f96869b509aa70b8593bdc0054aca6689bc1dd0324083d0fd2bcc3
21 changes: 10 additions & 11 deletions .github/actions/labeler/labeler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,8 @@ if (import.meta.url.endsWith(process.argv[1])) {
ignoreIfLabeled: boolEnvVar('IGNORE_IF_LABELED'),
}

// Actions pass comma-separated labels.
if (typeof ADD_LABELS === 'string') {
opts.addLabels = [...ADD_LABELS.split(',')].map((l) => l.trim())
} else {
opts.addLabels = []
}
if (typeof REMOVE_LABELS === 'string') {
opts.removeLabels = [...REMOVE_LABELS.split(',')].map((l) => l.trim())
} else {
opts.removeLabels = []
}
opts.addLabels = parseLabels(ADD_LABELS)
opts.removeLabels = parseLabels(REMOVE_LABELS)

const actionContext = getActionContext()
const { owner, repo } = actionContext
Expand All @@ -58,6 +49,14 @@ if (import.meta.url.endsWith(process.argv[1])) {
main(coreLib, octokit, opts)
}

// Actions pass comma-separated labels, and an omitted input arrives as an empty string.
export function parseLabels(value?: string): string[] {
return (value || '')
.split(',')
.map((l) => l.trim())
.filter(Boolean)
}

export default async function main(
core: typeof coreLib | CoreInject,
octokit: Octokit,
Expand Down
4 changes: 3 additions & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ updates:
['version-update:semver-patch', 'version-update:semver-minor']

- package-ecosystem: 'github-actions'
directory: '/'
directories:
- '/'
- '/.github/actions/*'
schedule:
interval: weekly
day: tuesday
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/auto-close-dependencies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
- 'Gemfile*'
- 'Dockerfile'
- '.github/workflows/**'
- '.github/actions/**'

permissions:
contents: write
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/changelog-agent.yml
Original file line number Diff line number Diff line change
Expand Up @@ -227,10 +227,12 @@ jobs:
const prNumber = parseInt('${{ steps.resolve_pr.outputs.pr_number }}', 10);
const prAuthor = '${{ steps.resolve_pr.outputs.pr_author }}';
const { data: reviews } = await github.rest.pulls.listReviews({
// Approvals often come after many comment reviews, so read every page
const reviews = await github.paginate(github.rest.pulls.listReviews, {
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: prNumber,
per_page: 100,
});
const approvedReviewers = [...new Set(
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ jobs:
with:
languages: javascript
- uses: github/codeql-action/analyze@e296a935590eb16afc0c0108289f68c87e2a89a5 # v4.30.7
continue-on-error: true
# Pull request scans stay non-blocking so analysis errors do not hold up merges.
# Push runs must fail so the alert steps below fire.
continue-on-error: ${{ github.event_name == 'pull_request' }}

- uses: ./.github/actions/create-workflow-failure-issue
id: create-failure-issue
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/confirm-internal-staff-work-in-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ name: Confirm internal staff meant to post in public

on:
issues:
# Issues moved into github/docs arrive as opened. The transferred event fires in the source repo.
types:
- opened
- transferred
# pull_request_target lets the workflow check org membership for forked PR authors.
pull_request_target:
types:
Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/dont-delete-assets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ jobs:

- name: Update comment
if: ${{ steps.comment.outputs.markdown != '' }}
# Fork PRs get a read-only token, so posting fails there. The next step still shows the instructions.
continue-on-error: true
uses: peter-evans/create-or-update-comment@e8674b075228eee787fea43ef493e45ece1004c9
with:
comment-id: ${{ steps.findComment.outputs.comment-id }}
Expand All @@ -53,7 +55,11 @@ jobs:

- name: Ultimately fail the workflow for attention
if: ${{ steps.comment.outputs.markdown != '' }}
env:
MARKDOWN: ${{ steps.comment.outputs.markdown }}
run: |
echo "More than 1 asset image was deleted as part of this PR."
echo "See posted PR commented about how to get them back."
echo "See the PR comment or this job's summary for how to get them back."
echo "$MARKDOWN" >> "$GITHUB_STEP_SUMMARY"
echo "$MARKDOWN"
exit 1
8 changes: 7 additions & 1 deletion .github/workflows/dont-delete-features.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ jobs:

- name: Update comment
if: ${{ steps.comment.outputs.markdown != '' }}
# Fork PRs get a read-only token, so posting fails there. The next step still shows the instructions.
continue-on-error: true
uses: peter-evans/create-or-update-comment@e8674b075228eee787fea43ef493e45ece1004c9
with:
comment-id: ${{ steps.findComment.outputs.comment-id }}
Expand All @@ -51,7 +53,11 @@ jobs:

- name: Ultimately fail the workflow for attention
if: ${{ steps.comment.outputs.markdown != '' }}
env:
MARKDOWN: ${{ steps.comment.outputs.markdown }}
run: |
echo "This PR deletes or renames one or more feature files."
echo "See the PR comment for how to get them back."
echo "See the PR comment or this job's summary for how to get them back."
echo "$MARKDOWN" >> "$GITHUB_STEP_SUMMARY"
echo "$MARKDOWN"
exit 1
21 changes: 13 additions & 8 deletions .github/workflows/generate-code-scanning-query-lists.yml
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,11 @@ jobs:
create-pull-request:
if: github.repository == 'github/docs-internal'
runs-on: ubuntu-latest
# Serialize publishing so a second run sees the first run's PR before it force-pushes.
# Pull request dry runs get their own group so they never queue behind or cancel a publisher.
concurrency:
group: ${{ github.workflow }}-query-table-publication-${{ github.event_name == 'pull_request' && github.run_id || 'publish' }}
cancel-in-progress: false
permissions:
contents: write
pull-requests: write
Expand Down Expand Up @@ -216,27 +221,27 @@ jobs:
branchname=codeql-query-tables-${{ steps.codeql.outputs.OPENAPI_COMMIT_SHA }}
# Query the remote because actions/checkout with fetch-depth 1 omits other remote-tracking branches.
branchExists=$(git ls-remote --heads origin refs/heads/$branchname | wc -l)
# Pull request runs validate generated files without pushing branches.
if [ "$DRY_RUN" = "true" ]; then
echo "Dry-run mode when run in a pull request"
echo "See the 'Insight into diff' step for the changes it would create PR about."
exit 0
fi
if [ $branchExists -ne 0 ]; then
echo "Branch $branchname already exists in the remote repository."
# Check for an open PR before pushing so reruns do not overwrite commits added to it.
existing_pr=$(gh pr list --repo github/docs-internal --head "$branchname" --json number --jq '.[0].number')
if [[ -n "$existing_pr" ]]; then
echo "Pull request #$existing_pr already exists for branch $branchname. Skipping PR creation."
exit 0
else
git checkout -b $branchname
fi
git checkout -b $branchname
git add data/reusables/code-scanning/codeql-query-tables
git add data/reusables/code-quality/codeql-query-tables
git commit -m "Update CodeQL query tables"
git push -u origin $branchname
# Force-push over a branch left by a failed attempt; this workflow exclusively owns these branches.
git push --force -u origin $branchname
echo "Creating pull request..."
gh pr create \
Expand Down
6 changes: 0 additions & 6 deletions .github/workflows/index-general-search.yml
Original file line number Diff line number Diff line change
Expand Up @@ -203,12 +203,6 @@ jobs:
curl --retry-connrefused --retry 5 ${{ env.ELASTICSEARCH_URL }}/_cat/indices?v
curl --retry-connrefused --retry 5 ${{ env.ELASTICSEARCH_URL }}/_cat/indices?v
- name: Purge Fastly edge cache
env:
FASTLY_TOKEN: ${{ secrets.FASTLY_TOKEN }}
FASTLY_SERVICE_ID: ${{ secrets.FASTLY_SERVICE_ID }}
run: npm run purge-fastly -- --surrogate-key api-search:${{ matrix.language }}

- name: Upload failures artifact
if: ${{ steps.check-failures.outputs.has_failures == 'true' }}
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/link-check-external.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ jobs:
env:
ACTION_RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
CACHE_MAX_AGE_DAYS: '7'
# The script checks github.com repo links through the REST API only when this is set.
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
if [[ -n "${{ inputs.max_urls }}" ]]; then
npm run check-links-external -- --max ${{ inputs.max_urls }}
Expand Down
15 changes: 9 additions & 6 deletions .github/workflows/link-check-internal.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,20 +124,23 @@ jobs:
}
const report = JSON.parse(fs.readFileSync(reportFile, 'utf8'))
const allRedirectGroups = report.groups.filter(g => g.isWarning)
// Raw redirect targets can carry the checked version's prefix; replacementTarget does not.
// Skip strings that could break out of the inline code spans, since directives must stay exact.
const isSafe = s => typeof s === 'string' && s.length > 0 && !/[`\r\n]/.test(s)
const allRedirectGroups = report.groups.filter(g =>
g.isWarning && g.fixStrategy === 'codemod' &&
isSafe(g.target) && isSafe(g.replacementTarget) && isSafe(g.occurrences[0]?.file))
const redirectGroups = allRedirectGroups.slice(0, 10)
if (redirectGroups.length === 0) {
core.info('No redirect groups found, skipping Copilot issue.')
core.info('No renamed redirects found, skipping Copilot issue.')
return
}
const directives = redirectGroups.map(g => {
const occ = g.occurrences[0]
const redirectTarget = occ?.redirectTarget ?? 'unknown'
const file = occ?.file ?? 'unknown'
const lines = (occ?.lines ?? []).join(', ') || 'unknown'
return `- Update \`${g.target}\` to \`${redirectTarget}\` in \`${file}\` (line(s): ${lines})`
const lines = (occ.lines ?? []).filter(Number.isInteger).join(', ') || 'unknown'
return `- Update \`${g.target}\` to \`${g.replacementTarget}\` in \`${occ.file}\` (line(s): ${lines})`
}).join('\n')
const artifactsUrl = `${context.serverUrl}/${context.repo.owner}/${context.repo.repo}/actions/runs/${context.runId}/artifacts`
Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/move-content.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ on:
pull_request:
paths:
- src/content-render/scripts/move-content.ts
- src/content-render/scripts/test-move-content.ts
- 'src/frame/lib/**/*.js'
- src/content-render/scripts/test-moved-content.ts
- 'src/frame/lib/**/*.ts'
- .github/workflows/move-content.yml
# Dependency changes can break the move-content script.
- 'package*.json'
- src/fixtures/fixtures/content/get-started/
- src/fixtures/fixtures/content/code-security/
- 'src/fixtures/fixtures/content/get-started/**'
- 'src/fixtures/fixtures/content/code-security/**'

permissions:
contents: read
Expand Down Expand Up @@ -50,8 +50,9 @@ jobs:
env:
ROOT: src/fixtures/fixtures
run: |
# The trailing slash on the old path matches what shell tab completion adds.
npm run move-content -- \
src/fixtures/fixtures/content/code-security/getting-started \
src/fixtures/fixtures/content/code-security/getting-started/ \
src/fixtures/fixtures/content/code-security/got-started
npm run test-moved-content -- \
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/no-response.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,13 @@ jobs:
runs-on: ubuntu-latest
# Only run in the public repo, and skip automated comments.
# Bot-authored issue_comment events are workflow chatter, not author responses.
# Scheduled runs often have a bot actor, so the actor check skips only comments.
if: >-
github.repository == 'github/docs' &&
github.actor != 'docs-bot' &&
(github.event_name != 'issue_comment' ||
(github.actor != 'docs-bot' &&
github.actor != 'github-actions' &&
!endsWith(github.actor, '[bot]')
!endsWith(github.actor, '[bot]')))
steps:
- uses: actions/stale@4391f3da665fdf50b6810c1a66712fb9ba21aa93 # v11.0.0
id: stale
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/notify-about-deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ jobs:
timeout-minutes: 5
env:
GITHUB_TOKEN: ${{ secrets.DOCS_BOT_PAT_BASE }}
# Manual Purge Fastly runs carry no deploy, so the script reads /_build instead.
DEPLOY_SHA: ${{ github.event.workflow_run.event == 'deployment_status' && github.event.workflow_run.head_sha || '' }}
run: npm run find-past-built-pr

- uses: ./.github/actions/create-workflow-failure-issue
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/orphaned-files-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,17 @@ on:
- cron: '20 16 * * 1'
pull_request:
paths:
- .github/workflows/orphaned-assets-check.yml
- .github/workflows/orphaned-files-check.yml
# Dependency changes can break the orphaned-files scripts.
- 'package*.json'
- src/assets/scripts/find-orphaned-assets.ts
- src/content-render/scripts/reusables-cli/find/unused.ts
- src/content-render/scripts/reusables-cli.ts
- 'src/content-render/scripts/reusables-cli/**'
- src/content-linter/lib/helpers/liquid-utils.ts
- src/data-directory/scripts/find-orphaned-tables.ts
- src/workflows/walk-files.ts
- src/languages/lib/languages.ts
- src/languages/lib/languages-server.ts
- .github/actions/clone-translations/action.yml
- .github/actions/node-npm-setup/action.yml

Expand Down Expand Up @@ -53,7 +55,9 @@ jobs:
# The -s flag keeps npm script-alias noise out of the file lists.
assetFilesToRemove=$(npm run -s find-orphaned-assets)
reusableFilesToRemove=$(npm run -s reusables -- find unused | grep '^data/reusables' || true)
# Keep the CLI out of the pipeline so set -e catches its failures; grep may match nothing.
reusablesOutput=$(npm run -s reusables -- find unused)
reusableFilesToRemove=$(printf '%s\n' "$reusablesOutput" | grep '^data/reusables' || true)
tableFilesToRemove=$(npm run -s find-orphaned-tables)
[ -z "$assetFilesToRemove" ] && [ -z "$reusableFilesToRemove" ] && [ -z "$tableFilesToRemove" ] && exit 0
Expand Down
9 changes: 8 additions & 1 deletion .github/workflows/reviewers-docs-engineering.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,19 @@ jobs:
PR_NUMBER: ${{ github.event.pull_request.number }}
CHANGED_FILES: ${{ github.event.pull_request.changed_files }}
REPO: ${{ github.repository }}
EVENT_ACTION: ${{ github.event.action }}
run: |
if [ "$PR_AUTHOR" = "dependabot[bot]" ] || [ "$PR_AUTHOR" = "docs-bot" ]; then
echo "Author is $PR_AUTHOR; skipping lockfile churn detection."
echo "lockfile_only=false" >> "$GITHUB_OUTPUT"
exit 0
fi
# Removing the lockfile-churn-only label and reopening the PR is the documented override.
if [ "$EVENT_ACTION" = "reopened" ]; then
echo "PR reopened; skipping lockfile churn detection."
echo "lockfile_only=false" >> "$GITHUB_OUTPUT"
exit 0
fi
# `gh pr diff` fails above 300 files, and `gh pr view --json files` stops at 100.
changed=$(gh api --paginate "repos/$REPO/pulls/$PR_NUMBER/files" --jq '.[].filename')
echo "Changed files:"
Expand Down Expand Up @@ -101,7 +108,7 @@ jobs:
git push
```
If the lockfile change is intentional, remove the `lockfile-churn-only` label and push or reopen the PR so this workflow sends it to the engineering review board.
If the lockfile change is intentional, remove the `lockfile-churn-only` label, then close and reopen the PR so this workflow sends it to the engineering review board.
EOF
gh pr comment "$PR" --body-file /tmp/lockfile-churn-body.md
gh pr edit "$PR" --add-label lockfile-churn-only
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/send-to-triage-board.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ name: Add new issues and PRs to central triage board

# Adds new, reopened, and ready-for-review github/docs work to the Central Triage Group board.
# Sets today's date so first responders can triage it.
# Skips PRs opened by docs-bot, such as Repo sync PRs, because they never need triage.

on:
issues:
Expand All @@ -15,7 +16,7 @@ permissions:
jobs:
add-to-central-triage:
runs-on: ubuntu-latest
if: github.repository == 'github/docs'
if: github.repository == 'github/docs' && github.event.pull_request.user.login != 'docs-bot'
steps:
- name: Triage to central triage board
env:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/triage-stale-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ jobs:
days-before-close: 7

stale-issue-message: 'A stale label has been added to this issue, because it has been open for 30 days with no activity. If you think this issue should remain open, please add a new comment.'
exempt-issue-labels: 'help wanted,never-stale,waiting for review'
exempt-issue-labels: 'help wanted,never-stale,waiting for review,needs SME'
stale-issue-label: 'Inactive'
close-issue-label: 'Closed as inactive'

exempt-pr-labels: 'never-stale,ready to merge,waiting for review'
exempt-pr-labels: 'never-stale,ready to merge,waiting for review,needs SME'
stale-pr-message: 'A stale label has been added to this pull request because it has been open 30 days with no activity. If you think this pull request should remain open, please add a new comment.'
stale-pr-label: 'Inactive'
close-pr-label: 'Closed as inactive'
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/validate-openapi-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@ on:
paths:
- 'Dockerfile.openapi_decorator'
- 'src/rest/scripts/openapi-check.ts'
- 'src/rest/scripts/utils/get-operations.ts'
- 'src/rest/scripts/utils/operation.ts'
# The check runs operation.ts and the helpers it imports.
- 'src/rest/scripts/utils/*.ts'
- 'src/tests/lib/validate-json-schema.ts'
- 'src/rest/fixtures/openapi-check-fixture.json'
- 'package.json'
- 'package-lock.json'
Expand Down
Loading
Loading