Skip to content

Commit 3f21935

Browse files
authored
Merge branch 'main' into lorensr-patch-1
2 parents c4a1cd0 + 546a0ca commit 3f21935

File tree

202 files changed

+9598
-5535
lines changed

Some content is hidden

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

202 files changed

+9598
-5535
lines changed

.devcontainer/devcontainer.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
},
1111

1212
// Set *default* container specific settings.json values on container create.
13-
"settings": {
13+
"settings": {
1414
"terminal.integrated.shell.linux": "/bin/bash",
1515
"cSpell.language": ",en"
1616
},
@@ -34,8 +34,8 @@
3434
"forwardPorts": [4000],
3535

3636
// Use 'postCreateCommand' to run commands after the container is created.
37-
"postCreateCommand": "npm ci && npm run build",
38-
37+
"postCreateCommand": "git lfs pull && npm ci",
38+
3939
// Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
4040
"remoteUser": "node"
4141

.github/workflows/main-preview-docker-cache.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ concurrency:
2020

2121
jobs:
2222
build-and-push-nonprod-cache:
23+
if: ${{ github.repository == 'github/docs-internal' || github.repository == 'github/docs' }}
2324
runs-on: ubuntu-latest
2425
timeout-minutes: 15
2526
env:
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Stale check for issues or PRs with "needs SME" label
2+
3+
# **What it does**: Provides stale checks on issues/PRs that need SME(subject matter expert) review on open source docs repo.
4+
# **Why we have it**: In the open repo, we want we want frequent checks on issues/PRs that are waiting on SME review.
5+
# **Who does it impact**: Anyone working in the open repo.
6+
7+
on:
8+
schedule:
9+
- cron: '40 20 * * *' # Run each day at 20:40 UTC / 12:40 PST
10+
11+
permissions:
12+
issues: write
13+
pull-requests: write
14+
15+
jobs:
16+
stale_needs-sme:
17+
if: ${{ github.repository == 'github/docs'' }}
18+
runs-on: ubuntu-latest
19+
20+
steps:
21+
- uses: actions/stale@7fb802b3079a276cf3c7e6ba9aa003c665b3f838
22+
with:
23+
only-labels: needs SME
24+
remove-stale-when-updated: true
25+
days-before-stale: 7 # adds stale label if no activity for 7 days
26+
stale-issue-message: 'This is a gentle bump for the docs team that this issue is waiting for technical review.'
27+
stale-issue-label: SME stale
28+
days-before-issue-close: -1 # never close
29+
stale-pr-message: 'This is a gentle bump for the docs team that this PR is waiting for technical review.'
30+
stale-pr-label: SME stale
31+
days-before-pr-close: -1 # never close
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Comment on adding "needs SME" label
2+
3+
# **What it does**: Comment on issues and pull requests when a "needs SME" label is added. SME = subject matter expert.
4+
# **Why we have it**: We want to manage our queue of issues and pull requests that need sme review.
5+
# **Who does it impact**: Everyone that works on docs or docs-internal.
6+
7+
on:
8+
issues:
9+
types: [labeled]
10+
pull_request_target:
11+
types: [labeled]
12+
13+
permissions:
14+
issues: write
15+
pull-requests: write
16+
17+
jobs:
18+
add-comment:
19+
if: ${{ github.repository == 'github/docs' && (github.event.label.name == 'needs SME' && github.event_name == 'issues' || github.event_name == 'pull_request_target') }}
20+
runs-on: ubuntu-latest
21+
steps:
22+
- uses: peter-evans/create-or-update-comment@a35cf36e5301d70b76f316e867e7788a55a31dae
23+
with:
24+
issue-number: ${{ github.event.issue.number }}
25+
body: |
26+
Thanks for opening an issue! We've triaged this issue for technical review by a subject matter expert :eyes:
27+
- uses: peter-evans/create-or-update-comment@a35cf36e5301d70b76f316e867e7788a55a31dae
28+
with:
29+
issue-number: ${{ github.event.pull_request.number }}
30+
body: |
31+
Thanks for opening a pull request! We've triaged this issue for technical review by a subject matter expert :eyes:

.github/workflows/sync-search-indices.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,18 @@ jobs:
7777
env:
7878
VERSION: ${{ github.event.inputs.version }}
7979
LANGUAGE: ${{ github.event.inputs.language }}
80+
# We don't want or need the changelog entries in this context.
81+
# Pages that display the content from these isn't included
82+
# in search index bodies anyway.
83+
CHANGELOG_DISABLED: true
84+
# If a reusable, or anything in the `data/*` directory is deleted
85+
# you might get a
86+
#
87+
# RenderError: Can't find the key 'site.data.reusables...' in the scope
88+
#
89+
# But that'll get fixed in the next translation pipeline. For now,
90+
# let's just accept an empty string instead.
91+
THROW_ON_EMPTY: false
8092
run: npm run sync-search
8193

8294
- name: Update private docs repository search indexes

.github/workflows/test.yml

Lines changed: 22 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,15 @@ jobs:
3131
fail-fast: false
3232
matrix:
3333
# The same array lives in test-windows.yml, so make any updates there too.
34-
test-group: [
34+
test-group:
35+
[
3536
content,
3637
graphql,
3738
meta,
3839
rendering,
3940
routing,
4041
unit,
41-
# linting,
42+
linting,
4243
translations,
4344
]
4445
steps:
@@ -47,7 +48,10 @@ jobs:
4748
- name: Check out repo
4849
uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579
4950
with:
50-
lfs: true
51+
# Not all test suites need the LFS files. So instead, we opt to
52+
# NOT clone them initially and instead, include them manually
53+
# only for the test groups that we know need the files.
54+
lfs: ${{ matrix.test-group == 'content' }}
5155
# Enables cloning the Early Access repo later with the relevant PAT
5256
persist-credentials: 'false'
5357

@@ -98,23 +102,25 @@ jobs:
98102
mv docs-early-access/data data/early-access
99103
rm -r docs-early-access
100104
105+
# This is necessary when LFS files where cloned but does nothing
106+
# if actions/checkout was run with `lfs:false`.
101107
- name: Checkout LFS objects
102108
run: git lfs checkout
103109

104-
# - name: Gather files changed
105-
# uses: trilom/file-changes-action@a6ca26c14274c33b15e6499323aac178af06ad4b
106-
# id: get_diff_files
107-
# with:
108-
# # So that `steps.get_diff_files.outputs.files` becomes
109-
# # a string like `foo.js path/bar.md`
110-
# output: ' '
110+
- name: Gather files changed
111+
uses: trilom/file-changes-action@a6ca26c14274c33b15e6499323aac178af06ad4b
112+
id: get_diff_files
113+
with:
114+
# So that `steps.get_diff_files.outputs.files` becomes
115+
# a string like `foo.js path/bar.md`
116+
output: ' '
111117

112-
# - name: Insight into changed files
113-
# run: |
118+
- name: Insight into changed files
119+
run: |
114120
115-
# # Must to do this because the list of files can be HUGE. Especially
116-
# # in a repo-sync when there are lots of translation files involved.
117-
# echo "${{ steps.get_diff_files.outputs.files }}" > get_diff_files.txt
121+
# Must to do this because the list of files can be HUGE. Especially
122+
# in a repo-sync when there are lots of translation files involved.
123+
echo "${{ steps.get_diff_files.outputs.files }}" > get_diff_files.txt
118124
119125
- name: Setup node
120126
uses: actions/setup-node@1f8c6b94b26d0feae1e387ca63ccbdc44d27b561
@@ -136,6 +142,6 @@ jobs:
136142

137143
- name: Run tests
138144
env:
139-
# DIFF_FILE: get_diff_files.txt
145+
DIFF_FILE: get_diff_files.txt
140146
CHANGELOG_CACHE_FILE_PATH: tests/fixtures/changelog-feed.json
141147
run: npm test -- tests/${{ matrix.test-group }}/
Binary file not shown.

0 commit comments

Comments
 (0)