-
Notifications
You must be signed in to change notification settings - Fork 9.9k
How we docs -> Content review #23807
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 5 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
1cb7e62
partial draft
kodster28 bee8168
updates
kodster28 baf4c7c
Added PR and issue ergonomics
kodster28 cded041
Finalize draft
kodster28 f9aa314
remove ghc reference
kodster28 c413d8b
Update src/content/docs/style-guide/how-we-docs/reviews.mdx
kodster28 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+93.5 KB
src/assets/images/style-guide/how-we-docs/potential-redirects-partials-comment.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,104 @@ | ||
| --- | ||
| pcx_content_type: how-to | ||
| title: Content reviews | ||
| meta: | ||
| title: Content reviews | How we docs | ||
| --- | ||
|
|
||
| import { GitHubCode } from "~/components"; | ||
|
|
||
| We work (and appreciate working) in [GitHub](https://github.com/cloudflare/cloudflare-docs), but it's not a perfect tool by any means. | ||
|
|
||
| We've added several ergonomic improvements to help us triage incoming work, streamline reviews, and automate communication. | ||
|
|
||
| ## Triage work | ||
|
|
||
| To help our writers triage work (and help with backend reporting), we automate a few labels and issue / pull request assignment. | ||
|
|
||
| ### Pull requests | ||
|
|
||
| For pull requests, we use a specific [GitHub action](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/workflows/pr-label-assign.yml) to add labels and assign codeowners. | ||
|
|
||
| - [Label products](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/actions/label-products/): We add labels for the top-level product folder, which helps writers scan incoming pull requests and see which are relevant to them. | ||
| - [Label size](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/actions/label-size/): We add labels for the size of the pull request, which helps writers see the relative size of the difference. It's not a perfect measure, but we use the lines changed to estimate the size of the pull request: | ||
|
|
||
| <GitHubCode | ||
| repo="cloudflare/cloudflare-docs" | ||
| file=".github/actions/label-size/index.ts" | ||
| commit="3dd03fdad79b2663631a6530794dfd1ad15bdc03" | ||
| lines="20-36" | ||
| lang="ts" | ||
| code={{ title: "label-size.ts" }} | ||
| /> | ||
|
|
||
| - [Assign codeowners](https://github.com/cloudflare/cloudflare-docs/tree/production/.github/actions/assign-pr): We use our [CODEOWNERS](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/CODEOWNERS) file to automatically assign people to pull requests based on the files changed. This assignment helps writers scan and filter to see which pull requests are relevant to them. | ||
|
|
||
| ### Issues | ||
|
|
||
| For issues, we use a similar [GitHub action](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/workflows/issue-label-assign.yml) to add labels and assign codeowners. | ||
|
|
||
| Our [script](https://github.com/cloudflare/cloudflare-docs/tree/production/.github/actions/issue-label-assign) treats issues because usually they contain links to our site instead of files within the repository. We grab the associated links in the issue description fields and then use those to assign writers (again based on `CODEOWNERS`) and add product labels. | ||
|
|
||
|
|
||
| ## Streamline reviews | ||
|
|
||
| To streamline reviews, we use several automations to help solve common reviewer issues. | ||
|
|
||
| ### Will this break anything? | ||
|
|
||
| We have one required check that runs on every commit, [CI](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/workflows/ci.yml). | ||
|
|
||
| This check makes sure that: | ||
|
|
||
| - The site builds correctly. | ||
| - All [internal links](/style-guide/how-we-docs/links/#internal-links) are valid. | ||
| - There are no [infinite redirects](/style-guide/how-we-docs/redirects/#infinite-redirects). | ||
| - Specific pages and functionality in our docs [behave as expected](https://github.com/cloudflare/cloudflare-docs/blob/production/worker/index.worker.test.ts). | ||
|
|
||
| ### Who needs to approve this? | ||
|
|
||
| We commonly get questions about approvals, especially for pull requests that touch multiple product areas (or our components). | ||
|
|
||
| We have a specific part of [CI](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/workflows/ci.yml#L32) that [posts a comment](https://github.com/cloudflare/cloudflare-docs/blob/production/bin/post-codeowners-comment/index.ts) with the relevant codeowners. | ||
|
|
||
|  | ||
|
|
||
| ### What changed? | ||
|
|
||
| We use a [GitHub action](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/workflows/publish-preview.yml) to publish preview builds for every commit on a pull request (and [comment those links](https://github.com/cloudflare/cloudflare-docs/tree/production/bin/post-preview-url-comment) on the pull request). This action ensures that reviewers always can know exactly what site will look like when it's rendered (and not just look at the changed markdown in GitHub). | ||
|
|
||
| We are in the process of migrating to [Workers Builds](/workers/ci-cd/builds/git-integration/github-integration/), which provides that functionality natively. | ||
|
|
||
| Based on feedback, we have also added a before/after table of links to help reviewers easily find links in the preview builds. | ||
|
|
||
|  | ||
|
|
||
| ### Is there anything else I need to check? | ||
|
|
||
| Two difficult things to check are potential redirects and changes to [content snippets (partials)](/style-guide/components/render/) that are used on multiple pages. | ||
|
|
||
| We have a [specific action](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/workflows/potential-redirects-or-partials.yml) that posts a comment to help reviewers identify and then check these attributes. | ||
|
|
||
|  | ||
|
|
||
| The partials part of the comment specifically [links to the usage for that partial](/style-guide/components/render/?partial=1.1.1.1/all-ipv4), which helps writers know the various pages where it appears. | ||
|
|
||
| ## Automate communication | ||
|
|
||
| We automate communication primarily through the [`no-response`](https://github.com/lee-dohm/no-response) GitHub Action. | ||
|
|
||
| Being open source means that we accept issues and pull requests from anyone! And a lot of these are either self explanatory or have enough context for us to follow up on them. | ||
|
|
||
| The ones without enough context, however, are often painful (especially in a [busy repo](https://github.com/cloudflare/cloudflare-docs/pulse) like ours). A writer has to ask for more detail, then remember to check back in, and then sometimes re-ask for more detail, and then check in again. | ||
|
|
||
| To help avoid some of this mental toil, we'll ask a question and then apply the `more-information-needed` label. This label starts a [14-day clock](https://github.com/cloudflare/cloudflare-docs/blob/production/.github/workflows/no-response.yml) for the author to respond. If they do respond, the label gets removed and the conversation can continue. If they don't respond, the issue automatically gets closed with a [comment explaining why](https://github.com/cloudflare/cloudflare-docs/issues/22943#issuecomment-3002211164). | ||
|
|
||
|  | ||
|
|
||
| This workflow - we hope - balances the needs our of team with a healthy respect for our contributors. | ||
|
|
||
| ### Stale issues | ||
|
|
||
| We intentionally avoid the [`stale` workflow](https://github.com/github/docs/blob/main/.github/workflows/stale.yml) that closes pull requests or issues that have been inactive for a specific period of time. | ||
|
|
||
| In our opinion, this workflow causes more friction and frustration than it solves. Just because something has been around for a year doesn't mean it's not still relevant. | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.