Skip to content

Commit 5bc50c9

Browse files
authored
docs: Update branch protection documentation
Update branch protection documentation
2 parents 0d95dfc + ab6fde3 commit 5bc50c9

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

website/docs/r/branch_protection.html.markdown

+5
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,11 @@ The following arguments are supported:
111111
* `strict`: (Optional) Require branches to be up to date before merging. Defaults to `false`.
112112
* `contexts`: (Optional) The list of status checks to require in order to merge into this branch. No status checks are required by default.
113113

114+
~> Note: This attribute can contain multiple string patterns.
115+
If specified, usual value is the [job name](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idname). Otherwise, the [job id](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idname) is defaulted to.
116+
For workflows that use matrixes, append the matrix name to the value using the following pattern `(<matrix_value>[, <matrix_value>])`. Matrixes should be specified based on the order of matrix properties in the workflow file. See [GitHub Documentation]("https://docs.github.com/en/actions/using-jobs/using-a-matrix-for-your-jobs#using-a-matrix-strategy") for more information.
117+
For workflows that use reusable workflows, the pattern is `<initial_workflow.jobs.job.[name/id]> / <reused-workflow.jobs.job.[name/id]>`. This can extend multiple levels.
118+
114119
### Required Pull Request Reviews
115120

116121
`required_pull_request_reviews` supports the following arguments:

website/docs/r/branch_protection_v3.html.markdown

+6
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,12 @@ The following arguments are supported:
9898

9999
* `strict`: (Optional) Require branches to be up to date before merging. Defaults to `false`.
100100
* `contexts`: [**DEPRECATED**] (Optional) The list of status checks to require in order to merge into this branch. No status checks are required by default.
101+
102+
~> Note: This attribute can contain multiple string patterns.
103+
If specified, usual value is the [job name](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idname). Otherwise, the [job id](https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idname) is defaulted to.
104+
For workflows that use matrixes, append the matrix name to the value using the following pattern `(<matrix_value>[, <matrix_value>])`. Matrixes should be specified based on the order of matrix properties in the workflow file. See [GitHub Documentation]("https://docs.github.com/en/actions/using-jobs/using-a-matrix-for-your-jobs#using-a-matrix-strategy") for more information.
105+
For workflows that use reusable workflows, the pattern is `<initial_workflow.jobs.job.[name/id]> / <reused-workflow.jobs.job.[name/id]>`. This can extend multiple levels.
106+
101107
* `checks`: (Optional) The list of status checks to require in order to merge into this branch. No status checks are required by default. Checks should be strings containing the context and app_id like so "context:app_id".
102108

103109
### Required Pull Request Reviews

0 commit comments

Comments
 (0)