Skip to content

Commit 555e1cd

Browse files
authored
Merge pull request #43253 from github/repo-sync
Repo sync
2 parents e4649ff + 0f90aa7 commit 555e1cd

106 files changed

Lines changed: 295 additions & 38 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/workflows/content-pipelines.yml‎

Lines changed: 34 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ jobs:
9191
fi
9292
9393
- name: Run content pipeline update script
94+
id: update
9495
env:
9596
GH_TOKEN: ${{ secrets.DOCS_BOT_PAT_BASE }}
9697
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -133,27 +134,48 @@ jobs:
133134
GH_TOKEN: ${{ secrets.DOCS_BOT_PAT_BASE }}
134135
UPDATE_BRANCH: ${{ steps.branch.outputs.update_branch }}
135136
PIPELINE_ID: ${{ matrix.id }}
137+
COMPARE_URL: ${{ steps.update.outputs.compare_url }}
138+
SHORT_RANGE: ${{ steps.update.outputs.short_range }}
136139
run: |
137140
PR_NUMBER="${{ steps.check-pr.outputs.pr_number }}"
138141
PR_TITLE="docs: update ${PIPELINE_ID} content from source docs"
139-
140-
PR_BODY="_GitHub Copilot generated this pull request._"$'\n\n'
141-
PR_BODY+="> [!NOTE]"$'\n'
142-
PR_BODY+="> This PR is **automatically generated** by the [content pipeline update workflow](${{ github.server_url }}/${{ github.repository }}/actions/workflows/content-pipelines.yml). Each run adds a new commit with any documentation changes detected."$'\n\n'
143-
PR_BODY+="## What this does"$'\n\n'
144-
PR_BODY+="Runs the \`content-pipeline-update\` agent (${PIPELINE_ID}) against the latest source docs and updates official articles under \`content/\` that have fallen out of sync."$'\n\n'
145-
PR_BODY+="## Review"$'\n\n'
146-
PR_BODY+="* Review each commit for accuracy — the agent uses AI, so spot-check important changes"$'\n'
147-
PR_BODY+="* To adjust agent behavior, see [Modifying results](${{ github.server_url }}/${{ github.repository }}/blob/main/src/content-pipelines/README.md#modifying-results)"$'\n'
148-
PR_BODY+="* Once satisfied, merge to keep docs up to date"$'\n'
149-
PR_BODY+="* A new PR will be created on the next run if there are further changes"
142+
NEW_ITEM="* [\`${SHORT_RANGE}\`](${COMPARE_URL})"
150143
151144
if [ -n "$PR_NUMBER" ]; then
152-
echo "PR #$PR_NUMBER already exists — new commit pushed"
145+
echo "PR #$PR_NUMBER already exists — appending source changes to body"
146+
147+
EXISTING_BODY=$(gh pr view "$PR_NUMBER" --json body --jq '.body')
148+
149+
# Append a new bullet before the SOURCE_CHANGES end marker
150+
# Uses bash parameter expansion for safe literal string replacement
151+
MARKER="<!-- /SOURCE_CHANGES -->"
152+
INSERTION="${NEW_ITEM}"$'\n'
153+
INSERTION+="${MARKER}"
154+
UPDATED_BODY="${EXISTING_BODY/$MARKER/$INSERTION}"
155+
156+
gh pr edit "$PR_NUMBER" --body "$UPDATED_BODY"
157+
153158
echo "Ensuring PR #$PR_NUMBER is marked ready for review"
154159
gh pr ready "$PR_NUMBER" || echo "Unable to mark PR #$PR_NUMBER as ready (it may already be ready)"
155160
else
156161
echo "Creating new PR"
162+
163+
PR_BODY="_GitHub Copilot generated this pull request._"$'\n\n'
164+
PR_BODY+="> [!NOTE]"$'\n'
165+
PR_BODY+="> This PR is **automatically generated** by the [content pipeline update workflow](${{ github.server_url }}/${{ github.repository }}/actions/workflows/content-pipelines.yml). Each run adds a new commit with any documentation changes detected."$'\n\n'
166+
PR_BODY+="## What this does"$'\n\n'
167+
PR_BODY+="Runs the \`content-pipeline-update\` agent (${PIPELINE_ID}) against the latest source docs and updates official articles under \`content/\` that have fallen out of sync."$'\n\n'
168+
PR_BODY+="## Source changes"$'\n\n'
169+
PR_BODY+="Changes in the source repo that triggered this update:"$'\n\n'
170+
PR_BODY+="<!-- SOURCE_CHANGES -->"$'\n'
171+
PR_BODY+="${NEW_ITEM}"$'\n'
172+
PR_BODY+="<!-- /SOURCE_CHANGES -->"$'\n\n'
173+
PR_BODY+="## Review"$'\n\n'
174+
PR_BODY+="* Review each commit for accuracy — the agent uses AI, so spot-check important changes"$'\n'
175+
PR_BODY+="* To adjust agent behavior, see [Modifying results](${{ github.server_url }}/${{ github.repository }}/blob/main/src/content-pipelines/README.md#modifying-results)"$'\n'
176+
PR_BODY+="* Once satisfied, merge to keep docs up to date"$'\n'
177+
PR_BODY+="* A new PR will be created on the next run if there are further changes"
178+
157179
gh pr create \
158180
--title "$PR_TITLE" \
159181
--body "$PR_BODY" \

‎.github/workflows/reviewers-docs-engineering.yml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ on:
2121
- 'src/**'
2222
- '!src/**.json' # So that Docs Engineering isn't reviewing automated pipeline data PRs
2323
- '!src/**.yml' # So that Docs Engineering isn't reviewing automated pipeline data PRs
24+
- '!src/**.sha' # So that Docs Engineering isn't reviewing automated pipeline data PRs
2425
- '.github/**'
2526
- 'config/**'
2627
- '.devcontainer/**'

‎content/get-started/accessibility/github-command-palette.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ versions:
66
shortTitle: GitHub Command Palette
77
redirect_from:
88
- /get-started/using-github/github-command-palette
9+
category:
10+
- Customize your experience
911
---
1012

1113
{% data reusables.command-palette.beta-note %}

‎content/get-started/accessibility/keyboard-shortcuts.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ versions:
1313
fpt: '*'
1414
ghes: '*'
1515
ghec: '*'
16+
category:
17+
- Customize your experience
1618
---
1719
## About keyboard shortcuts
1820

‎content/get-started/accessibility/managing-your-theme-settings.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ redirect_from:
1212
- /account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-personal-account-settings/managing-your-theme-settings
1313
- /account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-user-account-settings/managing-your-theme-settings
1414
shortTitle: Manage theme settings
15+
category:
16+
- Customize your experience
1517
---
1618

1719
For choice and flexibility in how and when you use {% data variables.product.github %}, you can configure theme settings to change how {% data variables.product.github %} looks to you. You can choose from themes that are light or dark, or you can configure {% data variables.product.github %} to follow your system settings.

‎content/get-started/archiving-your-github-personal-account-and-public-repositories/opting-into-or-out-of-the-github-archive-program-for-your-public-repository.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ versions:
99
fpt: '*'
1010
ghec: '*'
1111
shortTitle: GitHub Archive program
12+
category:
13+
- Set up your account on GitHub
1214
---
1315

1416
{% data reusables.repositories.about-github-archive-program %} For more information, see [AUTOTITLE](/repositories/archiving-a-github-repository/about-archiving-content-and-data-on-github#about-the-github-archive-program).

‎content/get-started/archiving-your-github-personal-account-and-public-repositories/requesting-an-archive-of-your-personal-accounts-data.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ versions:
1010
fpt: '*'
1111
ghec: '*'
1212
shortTitle: Request account archive
13+
category:
14+
- Set up your account on GitHub
1315
---
1416

1517
{% data variables.product.github %} stores repository and profile metadata from your personal account's activity. You can export your personal account's data through your account settings on {% data variables.product.prodname_dotcom %} or with the User Migration API.

‎content/get-started/exploring-projects-on-github/contributing-to-a-project.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ versions:
99
ghec: '*'
1010
redirect_from:
1111
- /get-started/quickstart/contributing-to-projects
12+
category:
13+
- Explore and contribute
1214
---
1315

1416
Contributing to a project on {% data variables.product.github %} is an essential skill for developers and collaborators working together to achieve shared goals. Whether you're fixing bugs, adding features, or improving documentation, the process of contributing ensures structured and efficient collaboration.

‎content/get-started/exploring-projects-on-github/contributing-to-open-source.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ versions:
66
ghes: '*'
77
ghec: '*'
88
shortTitle: Contribute to open source
9+
category:
10+
- Explore and contribute
911
---
1012

1113
In this article, you'll learn how to contribute to an open source project by working through an example. We'll guide you through making a contribution to the `github/docs` repository: familiarizing yourself with the repository, finding an area to contribute, making and submitting a pull request, and working with maintainers to get your changes accepted.

‎content/get-started/exploring-projects-on-github/finding-ways-to-contribute-to-open-source-on-github.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ versions:
1515
fpt: '*'
1616
ghec: '*'
1717
shortTitle: Finding open source projects
18+
category:
19+
- Explore and contribute
1820
---
1921

2022
Open source software powers much of the technology you use daily, from the web browser on your screen to the [NASA Ingenuity helicopter that flew on Mars](https://github.com/readme/featured/nasa-ingenuity-helicopter).

0 commit comments

Comments
 (0)