Skip to content

Commit 1a4294a

Browse files
authored
Merge branch 'main' into supported-ecosystems-clarification
2 parents df90ed6 + c940dcd commit 1a4294a

File tree

210 files changed

+3123
-1003
lines changed

Some content is hidden

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

210 files changed

+3123
-1003
lines changed

.devcontainer.json

+2-3
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,12 @@
22
// For format details, see https://aka.ms/vscode-remote/devcontainer.json
33
{
44
"name": "docs.github.com",
5-
"service": "container-doc",
65
"settings": {
76
"terminal.integrated.shell.linux": "/bin/bash",
87
"cSpell.language": ",en"
98
},
10-
// Install pre-requisites, and start to serve docs.github.com locally
11-
"postCreateCommand": "npm install && npm start",
9+
// Install pre-requisites and run a build to ensure we are ready to start serving docs.github.com locally (via `npm start`)
10+
"postCreateCommand": "npm ci && npm run build",
1211
"forwardPorts": [4000],
1312
// Visual Studio Code extensions which help authoring for docs.github.com.
1413
"extensions": [

.github/CODEOWNERS

+2
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
*.js @github/docs-engineering
88
/.github/ @github/docs-engineering
99
/script/ @github/docs-engineering
10+
/includes/ @github/docs-engineering
11+
/layouts/ @github/docs-engineering
1012
app.json @github/docs-engineering
1113
Dockerfile @github/docs-engineering
1214
package-lock.json @github/docs-engineering
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
---
2+
name: Change production configuration
3+
about: Track changes to the production docs.github.com site
4+
title: ''
5+
labels: engineering
6+
assignees: ''
7+
---
8+
9+
A configuration change would be something outside of our code that we change with our production environment, such as environment variables, virtual machine tier or quantity, or service providers.
10+
11+
- _Primary person_:
12+
- _Second person_:
13+
- _When_:
14+
- _Zoom URL_:
15+
16+
### What is the configuration change?
17+
18+
### Why are we updating this configuration?
19+
20+
### What risks are there with this configuration change?
21+
22+
### If an issue happens, how do we roll back?
23+
24+
Once the change is verified good, please close this issue.

.github/allowed-actions.js

+4-1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ module.exports = [
1111
"actions/setup-node@c46424eee26de4078d34105d3de3cc4992202b1e", //actions/[email protected]
1212
"ruby/setup-ruby@fdcfbcf14ec9672f6f615cb9589a1bc5dd69d262", //ruby/[email protected]
1313
"actions/stale@9d6f46564a515a9ea11e7762ab3957ee58ca50da", //actions/stale@v3.0.16
14+
"alex-page/github-project-automation-plus@fdb7991b72040d611e1123d2b75ff10eda9372c9",
15+
"andymckay/labeler@22d5392de2b725cea4b284df5824125054049d84",
1416
"archive/github-actions-slack@d368c5a4ad757515a9344918f84c490b05777d94",
1517
"ashley-taylor/regex-property-action@93a24f845cd20790924208225cc72da8b4c6d46d",
1618
"crowdin/github-action@fd9429dd63d6c0f8a8cb4b93ad8076990bd6e688",
@@ -21,17 +23,18 @@ module.exports = [
2123
"fkirc/skip-duplicate-actions@36feb0d8d062137530c2e00bd278d138fe191289",
2224
"github/codeql-action/analyze@v1",
2325
"github/codeql-action/init@v1",
24-
"ianwalter/puppeteer-container@2466ba8ecf689ccf4e5dfadeff3ac2db227b2e17",
2526
"juliangruber/approve-pull-request-action@c530832d4d346c597332e20e03605aa94fa150a8",
2627
"juliangruber/find-pull-request-action@2fc55e82a6d5d36fe1e7f1848f7e64fd02d99de9",
2728
"juliangruber/read-file-action@e0a316da496006ffd19142f0fd594a1783f3b512",
2829
"lee-dohm/close-matching-issues@22002609b2555fe18f52b8e2e7c07cbf5529e8a8",
30+
"octokit/graphql-action@5b3e01d42dee4509b0ac6b1cb2cf7778cdce85c2",
2931
"pascalgn/automerge-action@c9bd1823770819dc8fb8a5db2d11a3a95fbe9b07", //pascalgn/[email protected]
3032
"peter-evans/create-issue-from-file@a04ce672e3acedb1f8e416b46716ddfd09905326",
3133
"peter-evans/create-or-update-comment@5221bf4aa615e5c6e95bb142f9673a9c791be2cd",
3234
"peter-evans/create-pull-request@8c603dbb04b917a9fc2dd991dc54fef54b640b43",
3335
"rachmari/actions-add-new-issue-to-column@1a459ef92308ba7c9c9dc2fcdd72f232495574a9",
3436
"rachmari/labeler@832d42ec5523f3c6d46e8168de71cd54363e3e2e",
37+
"rachmari/puppeteer-container@6d56d6e132a3df76cf60bc290a4282f7fbaed05e",
3538
"repo-sync/github-sync@3832fe8e2be32372e1b3970bbae8e7079edeec88",
3639
"repo-sync/pull-request@33777245b1aace1a58c87a29c90321aa7a74bd7d",
3740
"someimportantcompany/github-actions-slack-message@0b470c14b39da4260ed9e3f9a4f1298a74ccdefd",

.github/commands/remove.yaml

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
trigger: remove-from-fr-board
2+
title: Remove from FR board
3+
description: Remove the current issue or pull request from the project board for the docs content first responder
4+
surfaces:
5+
- issue
6+
- pull_request
7+
- discussion
8+
steps:
9+
- type: repository_dispatch
10+
eventType: remove_from_FR_board

.github/workflows/browser-test.yml

+4-2
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,14 @@ jobs:
3939

4040
- if: ${{ needs.see_if_should_skip.outputs.should_skip != 'true' }}
4141
name: Install
42-
uses: ianwalter/puppeteer-container@2466ba8ecf689ccf4e5dfadeff3ac2db227b2e17
42+
uses: rachmari/puppeteer-container@6d56d6e132a3df76cf60bc290a4282f7fbaed05e
43+
timeout-minutes: 5
4344
with:
4445
args: npm ci
4546

4647
- if: ${{ needs.see_if_should_skip.outputs.should_skip != 'true' }}
4748
name: Test
48-
uses: ianwalter/puppeteer-container@2466ba8ecf689ccf4e5dfadeff3ac2db227b2e17
49+
timeout-minutes: 10
50+
uses: rachmari/puppeteer-container@6d56d6e132a3df76cf60bc290a4282f7fbaed05e
4951
with:
5052
args: npm run browser-test

.github/workflows/merged-notification.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,5 @@ jobs:
1515
github.issues.createComment({
1616
...context.repo,
1717
issue_number: context.payload.pull_request.number,
18-
body: 'Thanks very much for contributing! Your pull request has been merged 🎉 You should see your changes appear on the site in approximately 24 hours. If you're looking for your next contribution, check out our [help wanted issues](https://github.com/github/docs/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22) :zap:'
18+
body: "Thanks very much for contributing! Your pull request has been merged 🎉 You should see your changes appear on the site in approximately 24 hours. If you're looking for your next contribution, check out our [help wanted issues](https://github.com/github/docs/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22) :zap:"
1919
})
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Move help wanted issues
2+
on:
3+
issues:
4+
types:
5+
- labeled
6+
7+
jobs:
8+
move_issues:
9+
if: github.repository == 'github/docs' && (github.event.label.name == 'help wanted' || github.event.label.name == 'good first issue')
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: alex-page/github-project-automation-plus@fdb7991b72040d611e1123d2b75ff10eda9372c9
14+
with:
15+
project: Docs team reviews
16+
column: Help wanted
17+
repo-token: ${{ secrets.DOCUBOT_FR_PROJECT_BOARD_WORKFLOWS_REPO_ORG_READ_SCOPES }}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Move and unlabel ready to merge issues
2+
on:
3+
issues:
4+
types:
5+
- labeled
6+
7+
jobs:
8+
unmark_for_review:
9+
if: github.repository == 'github/docs' && github.event.label.name == 'ready to merge'
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: move issue
13+
uses: alex-page/github-project-automation-plus@fdb7991b72040d611e1123d2b75ff10eda9372c9
14+
with:
15+
project: Docs team reviews
16+
column: Triage
17+
repo-token: ${{ secrets.DOCUBOT_FR_PROJECT_BOARD_WORKFLOWS_REPO_ORG_READ_SCOPES }}
18+
- name: remove label
19+
uses: andymckay/labeler@22d5392de2b725cea4b284df5824125054049d84
20+
with:
21+
remove-labels: 'waiting for review'
22+
repo-token: ${{ secrets.GITHUB_TOKEN }}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
name: Remove card from FR board
2+
3+
on:
4+
repository_dispatch:
5+
types: remove_from_FR_board
6+
7+
jobs:
8+
remove_from_FR_board:
9+
if: github.repository == 'github/docs-internal'
10+
runs-on: ubuntu-latest
11+
steps:
12+
- id: find_project_cards
13+
uses: octokit/graphql-action@5b3e01d42dee4509b0ac6b1cb2cf7778cdce85c2
14+
with:
15+
query: |
16+
query($issue_node_id:ID!) {
17+
node(id:$issue_node_id) {
18+
... on Issue {
19+
projectCards(first: 10) {
20+
nodes {
21+
id
22+
project {
23+
name
24+
id
25+
}
26+
}
27+
}
28+
}
29+
... on PullRequest {
30+
projectCards(first: 10) {
31+
nodes {
32+
id
33+
project {
34+
name
35+
id
36+
}
37+
}
38+
}
39+
}
40+
}
41+
}
42+
issue_node_id: ${{ github.event.client_payload.command.resource.id }}
43+
env:
44+
GITHUB_TOKEN: ${{ secrets.DOCUBOT_FR_PROJECT_BOARD_WORKFLOWS_REPO_ORG_READ_SCOPES }}
45+
46+
- run: "echo 'Project cards found: ${{ steps.find_project_cards.outputs.data }}'"
47+
48+
- name: Get FR card
49+
env:
50+
QUERY_DATA: ${{ steps.find_project_cards.outputs.data }}
51+
run: |
52+
echo 'FR_CARDS='$(jq '.node.projectCards.nodes | .[] | select(.project.id == "MDc6UHJvamVjdDQ1NzI0ODI=") | .id' <<< "$QUERY_DATA") >> $GITHUB_ENV
53+
54+
- name: Delete card
55+
id: delete_project_card
56+
if: ${{ env.FR_CARDS }}
57+
uses: octokit/graphql-action@5b3e01d42dee4509b0ac6b1cb2cf7778cdce85c2
58+
with:
59+
query: |
60+
mutation DeleteCard {
61+
deleteProjectCard(input:{cardId:${{ env.FR_CARDS }}}) {deletedCardId}
62+
}
63+
env:
64+
GITHUB_TOKEN: ${{ secrets.DOCUBOT_FR_PROJECT_BOARD_WORKFLOWS_REPO_ORG_READ_SCOPES }}

.github/workflows/site-policy-sync.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ on:
1818
jobs:
1919
# This workflow contains a single job called "build"
2020
copy-file:
21-
if: github.repository == 'github/docs-internal' || github.repository == 'github/docs'
21+
if: github.repository == 'github/docs-internal'
2222
# The type of runner that the job will run on
2323
runs-on: ubuntu-latest
2424

Loading
30.4 KB
Loading
Loading
Loading
Loading
Loading
Binary file not shown.
Loading

content/actions/creating-actions/metadata-syntax-for-github-actions.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ runs:
299299

300300
#### `runs.image`
301301

302-
**Required** The Docker image to use as the container to run the action. The value can be the Docker base image name, a local `Dockerfile` in your repository, or a public image in Docker Hub or another registry. To reference a `Dockerfile` local to your repository, use a path relative to your action metadata file. The `docker` application will execute this file.
302+
**Required** The Docker image to use as the container to run the action. The value can be the Docker base image name, a local `Dockerfile` in your repository, or a public image in Docker Hub or another registry. To reference a `Dockerfile` local to your repository, the file must be named `Dockerfile` and you must use a path relative to your action metadata file. The `docker` application will execute this file.
303303

304304
#### `runs.env`
305305

content/actions/guides/about-continuous-integration.md

+20
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,26 @@ For a definition of common terms, see "[Core concepts for {% data variables.prod
5353

5454
Browse the complete list of CI workflow templates offered by {% data variables.product.product_name %} in the {% if currentVersion == "free-pro-team@latest" %}[actions/starter-workflows](https://github.com/actions/starter-workflows/tree/main/ci) repository{% else %} `actions/starter-workflows` repository on {% data variables.product.product_location %}{% endif %}.
5555

56+
### Skipping workflow runs
57+
58+
If you want to temporarily prevent a workflow from being triggered, you can add a skip instruction to the commit message. Workflows that would otherwise be triggered `on: push` or `on: pull_request`, won't be triggered if you add any any of the following strings to the commit message in a push, or the HEAD commit of a pull request:
59+
60+
* `[skip ci]`
61+
* `[ci skip]`
62+
* `[no ci]`
63+
* `[skip actions]`
64+
* `[actions skip]`
65+
66+
Alternatively, you can end the commit message with two empty lines followed by either `skip-checks: true` or `skip-checks:true`.
67+
68+
You won't be able to merge the pull request if your repository is configured to require specific checks to pass first. To allow the pull request to be merged you can push a new commit to the pull request without the skip instruction in the commit message.
69+
70+
{% note %}
71+
72+
**Note:** Skip instructions only apply to the `push` and `pull_request` events. For example, adding `[skip ci]` to a commit message won't stop a workflow that's triggered `on: pull_request_target` from running.
73+
74+
{% endnote %}
75+
5676
### Notifications for workflow runs
5777

5878
{% data reusables.repositories.workflow-notifications %}

content/actions/guides/building-and-testing-net.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ jobs:
4949
steps:
5050
- uses: actions/checkout@v2
5151
- name: Setup .NET Core SDK ${{ matrix.dotnet }}
52-
uses: actions/setup-dotnet@v1.6.0
52+
uses: actions/setup-dotnet@v1.7.2
5353
with:
5454
dotnet-version: ${{ matrix.dotnet-version }}
5555
- name: Install dependencies
@@ -86,7 +86,7 @@ jobs:
8686
steps:
8787
- uses: actions/checkout@v2
8888
- name: Setup dotnet ${{ matrix.dotnet-version }}
89-
uses: actions/setup-dotnet@v1.6.0
89+
uses: actions/setup-dotnet@v1.7.2
9090
with:
9191
dotnet-version: ${{ matrix.dotnet-version }}
9292
# You can test your matrix by printing the current dotnet version
@@ -118,7 +118,7 @@ You can configure your job to use a specific version of .NET, such as `3.1.3`. A
118118
steps:
119119
- uses: actions/checkout@v2
120120
- name: Setup dotnet
121-
uses: actions/setup-dotnet@v1.6.0
121+
uses: actions/setup-dotnet@v1.7.2
122122
with:
123123
dotnet-version: '3.1.x'
124124
- name: Install dependencies
@@ -139,7 +139,7 @@ For more information, see "[Caching dependencies to speed up workflows](/actions
139139
steps:
140140
- uses: actions/checkout@v2
141141
- name: Setup dotnet
142-
uses: actions/setup-dotnet@v1.6.0
142+
uses: actions/setup-dotnet@v1.7.2
143143
with:
144144
dotnet-version: '3.1.x'
145145
- uses: actions/cache@v2
@@ -171,7 +171,7 @@ You can use the same commands that you use locally to build and test your code.
171171
steps:
172172
- uses: actions/checkout@v2
173173
- name: Setup dotnet
174-
uses: actions/setup-dotnet@v1.6.0
174+
uses: actions/setup-dotnet@v1.7.2
175175
with:
176176
dotnet-version: '3.1.x'
177177
- name: Install dependencies
@@ -206,7 +206,7 @@ jobs:
206206
steps:
207207
- uses: actions/checkout@v2
208208
- name: Setup dotnet
209-
uses: actions/setup-dotnet@v1.6.0
209+
uses: actions/setup-dotnet@v1.7.2
210210
with:
211211
dotnet-version: ${{ matrix.dotnet-version }}
212212
- name: Install dependencies

content/actions/guides/caching-dependencies-to-speed-up-workflows.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Workflow runs often reuse the same outputs or downloaded dependencies from one r
2222

2323
Jobs on {% data variables.product.prodname_dotcom %}-hosted runners start in a clean virtual environment and must download dependencies each time, causing increased network utilization, longer runtime, and increased cost. To help speed up the time it takes to recreate these files, {% data variables.product.prodname_dotcom %} can cache dependencies you frequently use in workflows.
2424

25-
To cache dependencies for a job, you'll need to use {% data variables.product.prodname_dotcom %}'s `cache` action. The action retrieves a cache identified by a unique key. For more information, see [`actions/cache`](https://github.com/actions/cache).
25+
To cache dependencies for a job, you'll need to use {% data variables.product.prodname_dotcom %}'s `cache` action. The action retrieves a cache identified by a unique key. For more information, see [`actions/cache`](https://github.com/actions/cache). If you are caching Ruby gems, instead consider using the Ruby maintained action, which can cache bundle installs on initiation. For more information, see [`ruby/setup-ruby`](https://github.com/ruby/setup-ruby#caching-bundle-install-automatically).
2626

2727
{% warning %}
2828

content/actions/learn-github-actions/essential-features-of-github-actions.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ jobs:
7575
run: |
7676
expr 1 + 1 > output.log
7777
- name: Upload output file
78-
uses: actions/upload-artifact@v1
78+
uses: actions/upload-artifact@v2
7979
with:
8080
name: output-log-file
8181
path: output.log

content/actions/learn-github-actions/migrating-from-circleci-to-github-actions.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ GitHub Actions
117117
</tr>
118118
</table>
119119
120-
{% data variables.product.prodname_actions %} caching is only applicable to {% data variables.product.prodname_dotcom %}-hosted runners. For more information, see "<a href="/actions/guides/caching-dependencies-to-speed-up-workflows" class="dotcom-only">Caching dependencies to speed up workflows</a>."
120+
{% data variables.product.prodname_actions %} caching is only applicable for repositories hosted on {% data variables.product.prodname_dotcom_the_website %}. For more information, see "<a href="/actions/guides/caching-dependencies-to-speed-up-workflows" class="dotcom-only">Caching dependencies to speed up workflows</a>."
121121
122122
{% data variables.product.prodname_actions %} does not have an equivalent of CircleCI’s Docker Layer Caching (or DLC).
123123

content/actions/learn-github-actions/security-hardening-for-github-actions.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ This means that a compromise of a single action within a workflow can be very si
7777

7878
### Considering cross-repository access
7979

80-
{% data variables.product.product_name %} is intentionally scoped for a single repository at a time. The `GITHUB_TOKEN` grants the same level of access as a write-access user, because any write-access user can access this token by creating or modifying workflow files. Users have specific permissions for each repository, so having the `GITHUB_TOKEN` for one repository grant access to another would impact the {% data variables.product.prodname_dotcom %} permission model if not implemented carefully. Similarly, caution must be taken when adding {% data variables.product.prodname_dotcom %} authentication tokens to a workflow, because this can also affect the {% data variables.product.prodname_dotcom %} permission model by inadvertently granting broad access to collaborators.
80+
{% data variables.product.prodname_actions %} is intentionally scoped for a single repository at a time. The `GITHUB_TOKEN` grants the same level of access as a write-access user, because any write-access user can access this token by creating or modifying workflow files. Users have specific permissions for each repository, so allowing the `GITHUB_TOKEN` for one repository to grant access to another would impact the {% data variables.product.prodname_dotcom %} permission model if not implemented carefully. Similarly, caution must be taken when adding {% data variables.product.prodname_dotcom %} authentication tokens to a workflow, because this can also affect the {% data variables.product.prodname_dotcom %} permission model by inadvertently granting broad access to collaborators.
8181

8282
We have [a plan on the {% data variables.product.prodname_dotcom %} roadmap](https://github.com/github/roadmap/issues/74) to support a flow that allows cross-repository access within {% data variables.product.product_name %}, but this is not yet a supported feature. Currently, the only way to perform privileged cross-repository interactions is to place a {% data variables.product.prodname_dotcom %} authentication token or SSH key as a secret within the workflow. Because many authentication token types do not allow for granular access to specific resources, there is significant risk in using the wrong token type, as it can grant much broader access than intended.
8383

content/actions/reference/authentication-in-a-workflow.md

+2
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,8 @@ For information about the API endpoints {% data variables.product.prodname_githu
9595
| repository projects | read/write | read |
9696
| statuses | read/write | read |
9797

98+
{% data reusables.actions.workflow-runs-dependabot-note %}
99+
98100
If you need a token that requires permissions that aren't available in the `GITHUB_TOKEN`, you can create a personal access token and set it as a secret in your repository:
99101

100102
1. Use or create a token with the appropriate permissions for that repository. For more information, see "[Creating a personal access token](/github/authenticating-to-github/creating-a-personal-access-token)."

content/actions/reference/encrypted-secrets.md

+6
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,12 @@ When generating credentials, we recommend that you grant the minimum permissions
7777

7878
If your repository {% if currentVersion == "free-pro-team@latest" or currentVersion ver_gt "[email protected]"or currentVersion == "github-ae@latest" %}has environment secrets or {% endif %}can access secrets from the parent organization, then those secrets are also listed on this page.
7979

80+
{% note %}
81+
82+
**Note:** Users with collaborator access can use the REST API to manage secrets for a repository. For more information, see "[{% data variables.product.prodname_actions %} secrets API](/rest/reference/actions#secrets)."
83+
84+
{% endnote %}
85+
8086
{% if currentVersion == "free-pro-team@latest" or currentVersion ver_gt "[email protected]" or currentVersion == "github-ae@latest" }
8187
### Creating encrypted secrets for an environment
8288

0 commit comments

Comments
 (0)