You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# **What it does**: When a PR is opened in docs-internal or docs containing code, it comments with instructions on how to deploy and preview the changes.
4
+
# **Why we have it**: To help Docs contributors understand how to preview their changes.
5
+
# **Who does it impact**: docs-internal and docs maintainers and contributors
6
+
7
+
on:
8
+
# Required in lieu of `pull_request` so that the comment can be posted to PRs opened from a fork.
9
+
pull_request_target:
10
+
types:
11
+
- opened
12
+
- synchronize
13
+
# this applies to any non-content files, this workflow will run for all changed files unless it's ONLY these content-related changes
14
+
paths-ignore:
15
+
- 'content/**'
16
+
- 'data/reusables/**'
17
+
- 'assets/images/**'
18
+
19
+
permissions:
20
+
contents: read
21
+
pull-requests: write
22
+
23
+
# This allows a subsequently queued workflow run to interrupt previous runs
# TODO: We'll update this comment at a later time with permament-ish links to deployment instructions.
47
+
- name: Comment on code changes
48
+
if: ${{ !steps.findComment.outputs.comment-id }}
49
+
run: |
50
+
if [[ "${{ github.repository }}" == "github/docs" ]]; then
51
+
COMMENT_BODY="<!-- CODE_CHANGES_COMMENT -->
52
+
## 🚀 Manual Deployment Required
53
+
54
+
It looks like this pull request contains code changes. To preview these changes, an internal Hubber will need to manually deploy the changes to one of our staging servers.
55
+
56
+
Thank you for your contribution!"
57
+
else
58
+
COMMENT_BODY="<!-- CODE_CHANGES_COMMENT -->
59
+
## 🚀 Manual Deployment Required
60
+
61
+
It looks like this pull request contains code changes. To preview these changes, you will need to deploy them manually.
**This comment is automatically generated and will be overwritten every time changes are committed to this branch.**
92
+
## 👓 Previews for changed content
93
+
**This comment is 🤖 automatically generated and will be overwritten every time changes are committed to this branch.**
86
94
87
-
The table contains an overview of files in the `content` directory that have been changed in this pull request. It's provided to make it easy to review your changes on the staging site. Please note that changes to the `data` directory will not show up in this table.
95
+
The table contains an overview of files in the `content` directory that have been changed in this pull request. It's provided to make it easy to review your changes on the review server. Please note that changes to the `data` directory will not show up in this table.
_This table is posted from the [${{ github.workflow }}](https://github.com/${{ github.repository }}/blob/${{ github.sha }}/.github/workflows/content-changes-table-comment.yml) workflow._
0 commit comments