Skip to content

Commit 65e3aab

Browse files
authored
Merge pull request #39670 from github/repo-sync
Repo sync
2 parents 8315322 + 07af0c1 commit 65e3aab

File tree

124 files changed

+1430
-377
lines changed

Some content is hidden

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

124 files changed

+1430
-377
lines changed

.github/workflows/readability.yml

Lines changed: 108 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,108 @@
1+
name: Readability report
2+
3+
# **What it does**: Analyzes readability of rendered content for changed Markdown files in pull requests
4+
# **Why we have it**: We want to track and improve the readability of our documentation over time
5+
# **Who does it impact**: Contributors and content writers
6+
7+
on:
8+
# pull_request:
9+
# paths:
10+
# - 'content/**/*.md'
11+
# - 'data/reusables/**/*.md'
12+
# The pull_request trigger is currently disabled for testing purposes.
13+
# Re-enable this trigger when ready to run readability analysis automatically on PRs.
14+
workflow_dispatch:
15+
inputs:
16+
pull_request_number:
17+
description: 'Pull request number to analyze (for testing)'
18+
required: true
19+
type: number
20+
21+
permissions:
22+
contents: read
23+
pull-requests: write
24+
25+
jobs:
26+
readability-analysis:
27+
if: github.repository == 'github/docs-internal'
28+
runs-on: ${{ fromJSON('["ubuntu-latest", "ubuntu-20.04-xl"]')[github.repository == 'github/docs-internal'] }}
29+
steps:
30+
- name: Check out repo with full history
31+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
32+
with:
33+
fetch-depth: 0
34+
35+
- name: Checkout PR for manual dispatch
36+
if: ${{ github.event_name == 'workflow_dispatch' }}
37+
run: |
38+
gh pr checkout ${{ inputs.pull_request_number }}
39+
env:
40+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
41+
42+
- uses: ./.github/actions/node-npm-setup
43+
44+
- uses: ./.github/actions/get-docs-early-access
45+
if: ${{ github.repository == 'github/docs-internal' }}
46+
with:
47+
token: ${{ secrets.DOCS_BOT_PAT_BASE }}
48+
49+
- name: Get changed content files
50+
id: changed_files
51+
uses: ./.github/actions/get-changed-files
52+
with:
53+
files: 'content/**/*.md'
54+
# For workflow_dispatch, compare against main
55+
base: ${{ github.event_name == 'workflow_dispatch' && 'main' || '' }}
56+
57+
- name: Disable Next.js telemetry
58+
run: npx next telemetry disable
59+
60+
- name: Start server in the background
61+
if: ${{ steps.changed_files.outputs.filtered_changed_files }}
62+
run: npm start > /tmp/stdout.log 2> /tmp/stderr.log &
63+
64+
- name: Run readability analysis
65+
if: ${{ steps.changed_files.outputs.filtered_changed_files }}
66+
env:
67+
CHANGED_FILES: ${{ steps.changed_files.outputs.filtered_changed_files }}
68+
run: npm run readability-report
69+
70+
- name: Find existing readability comment
71+
if: ${{ steps.changed_files.outputs.filtered_changed_files }}
72+
uses: peter-evans/find-comment@3eae4d37986fb5a8592848f6a574fdf654e61f9e
73+
id: findComment
74+
with:
75+
issue-number: ${{ github.event_name == 'workflow_dispatch' && inputs.pull_request_number || github.event.number }}
76+
comment-author: 'github-actions[bot]'
77+
body-includes: '<!-- READABILITY_REPORT -->'
78+
79+
- name: Read readability report
80+
if: ${{ steps.changed_files.outputs.filtered_changed_files }}
81+
id: read_report
82+
run: |
83+
if [ -f "readability-report.md" ]; then
84+
{
85+
echo 'report<<EOF'
86+
cat readability-report.md
87+
echo EOF
88+
} >> "$GITHUB_OUTPUT"
89+
fi
90+
91+
- name: Create or update readability comment
92+
if: ${{ steps.changed_files.outputs.filtered_changed_files && steps.read_report.outputs.report }}
93+
uses: peter-evans/create-or-update-comment@71345be0265236311c031f5c7866368bd1eff043
94+
with:
95+
comment-id: ${{ steps.findComment.outputs.comment-id }}
96+
issue-number: ${{ github.event_name == 'workflow_dispatch' && inputs.pull_request_number || github.event.number }}
97+
body: |
98+
<!-- READABILITY_REPORT -->
99+
${{ steps.read_report.outputs.report }}
100+
edit-mode: replace
101+
102+
- if: ${{ failure() }}
103+
name: Debug server outputs on errors
104+
run: |
105+
echo "____STDOUT____"
106+
cat /tmp/stdout.log || echo "No stdout log found"
107+
echo "____STDERR____"
108+
cat /tmp/stderr.log || echo "No stderr log found"
20.1 KB
Loading
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
title: How-tos for your GitHub account and profile
3+
shortTitle: How-tos
4+
intro: 'Learn how to accomplish specific tasks for your {% data variables.product.github %} account and profile.'
5+
versions:
6+
fpt: '*'
7+
ghes: '*'
8+
ghec: '*'
9+
children:
10+
- /setting-up-and-managing-your-github-profile
11+
- /setting-up-and-managing-your-personal-account-on-github
12+
---
13+

content/account-and-profile/setting-up-and-managing-your-github-profile/customizing-your-profile/index.md renamed to content/account-and-profile/how-tos/setting-up-and-managing-your-github-profile/customizing-your-profile/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ intro: You can customize your profile so that other people can get a better sens
44
redirect_from:
55
- /articles/customizing-your-profile
66
- /github/setting-up-and-managing-your-github-profile/customizing-your-profile
7+
- /account-and-profile/setting-up-and-managing-your-github-profile/customizing-your-profile
78
versions:
89
fpt: '*'
910
ghes: '*'
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ permissions: 'Profile READMEs are not available to {% data variables.enterprise.
1111
redirect_from:
1212
- /github/setting-up-and-managing-your-github-profile/managing-your-profile-readme
1313
- /github/setting-up-and-managing-your-github-profile/customizing-your-profile/managing-your-profile-readme
14+
- /account-and-profile/setting-up-and-managing-your-github-profile/customizing-your-profile/managing-your-profile-readme
1415
shortTitle: Your profile README
1516
---
1617
## About your profile README
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ redirect_from:
66
- /articles/pinning-items-to-your-profile
77
- /github/setting-up-and-managing-your-github-profile/pinning-items-to-your-profile
88
- /github/setting-up-and-managing-your-github-profile/customizing-your-profile/pinning-items-to-your-profile
9+
- /account-and-profile/setting-up-and-managing-your-github-profile/customizing-your-profile/pinning-items-to-your-profile
910
versions:
1011
fpt: '*'
1112
ghes: '*'
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ versions:
66
topics:
77
- Profiles
88
shortTitle: Set profile to private
9+
redirect_from:
10+
- /account-and-profile/setting-up-and-managing-your-github-profile/customizing-your-profile/setting-your-profile-to-private
911
---
1012
## About private profiles
1113

content/account-and-profile/setting-up-and-managing-your-github-profile/index.md renamed to content/account-and-profile/how-tos/setting-up-and-managing-your-github-profile/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ shortTitle: Profiles
55
redirect_from:
66
- /categories/setting-up-and-managing-your-github-profile
77
- /github/setting-up-and-managing-your-github-profile
8+
- /account-and-profile/setting-up-and-managing-your-github-profile
89
versions:
910
fpt: '*'
1011
ghes: '*'
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ redirect_from:
55
- /articles/managing-contribution-graphs-on-your-profile
66
- /github/setting-up-and-managing-your-github-profile/managing-contribution-graphs-on-your-profile
77
- /account-and-profile/setting-up-and-managing-your-github-profile/managing-contribution-graphs-on-your-profile
8+
- /account-and-profile/setting-up-and-managing-your-github-profile/managing-contribution-settings-on-your-profile
89
versions:
910
fpt: '*'
1011
ghes: '*'
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ redirect_from:
99
- /github/setting-up-and-managing-your-github-profile/managing-contribution-graphs-on-your-profile/sending-your-github-enterprise-server-contributions-to-your-githubcom-profile
1010
- /account-and-profile/setting-up-and-managing-your-github-profile/managing-contribution-graphs-on-your-profile/sending-enterprise-contributions-to-your-githubcom-profile
1111
- /account-and-profile/setting-up-and-managing-your-github-profile/managing-contribution-settings-on-your-profile/sending-enterprise-contributions-to-your-githubcom-profile
12+
- /account-and-profile/setting-up-and-managing-your-github-profile/managing-contribution-settings-on-your-profile/sharing-contributions-from-github-enterprise-server
1213
versions:
1314
fpt: '*'
1415
ghes: '*'

0 commit comments

Comments
 (0)