Skip to content

Commit a876ea0

Browse files
author
Danny Hermes
committed
Releasing (2022.02.04) after renaming this project.
Changed strategy on project README to enable better release docs in the GitHub Actions marketplace.
1 parent 7aea561 commit a876ea0

14 files changed

+83
-8
lines changed

README.md

+79-4
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,85 @@
1-
# GitHub Action: Composite
1+
# GitHub Action: Require Conditional Status Checks
22

3-
This GitHub Action is developed in the `development` [branch][1] of this
4-
repository, in particular via the command in `cmd/composite/`.
3+
## Example Usage
4+
5+
```yaml
6+
---
7+
name: 'Meta Workflow: Require Conditional Status Checks'
8+
9+
on:
10+
pull_request:
11+
branches:
12+
- main
13+
14+
jobs:
15+
meta:
16+
runs-on:
17+
- ubuntu-20.04
18+
19+
steps:
20+
- name: Ensure All Conditional Checks Have Passed
21+
uses: blend/[email protected]
22+
with:
23+
interval: 20s
24+
checks-yaml: |
25+
- job: unit-test-go-core
26+
paths:
27+
- cmd/**
28+
- pkg/**
29+
- job: lint-go
30+
- job: protobuf-check-generated
31+
paths:
32+
- proto/**
33+
- pkg/protogen/**
34+
- job: lint-protobuf
35+
paths:
36+
- proto/**
37+
```
38+
39+
Alternatively, the `checks-yaml` can be checked into a file in your repository
40+
41+
```yaml
42+
# ...
43+
steps:
44+
- name: Ensure All Conditional Checks Have Passed
45+
uses: blend/[email protected]
46+
with:
47+
interval: 20s
48+
checks-filename: .github/monorepo/required-checks.yml
49+
# ...
50+
```
51+
52+
## See It In Action
53+
54+
From a recent workflow run on public GitHub:
55+
56+
![Example Workflow Public][2]
57+
58+
From a recent workflow on GitHub Enterprise:
59+
60+
![Example Workflow GHE][3]
61+
62+
## Limitations
63+
64+
- The GitHub `CompareCommits()` [API][1] can return at most 300 files
65+
when comparing two commits. This makes it impossible to determine the
66+
full list of impacted files for PRs with 300 or more files. The list
67+
of files is critical for `blend/require-conditional-status-checks` to determine which
68+
checks to enforce.
69+
70+
## Development
71+
72+
This GitHub Action is developed in the `development` [branch][5] of this
73+
repository, in particular via the command in `cmd/requireconditional/`.
574

675
The documentation and source code for this action are maintained there. This
776
branch is intended to be as small as possible so it can be loaded quickly
877
when new jobs retrieve it when spawned as part of a GitHub Actions workflow.
78+
For more information on how this GitHub Action is developed, see the
79+
[DEVELOPMENT][4] document.
980

10-
[1]: https://github.com/blend/action-composite/tree/7586da331a1ce003a321cc16ac72319d78c7764b
81+
[1]: https://docs.github.com/en/free-pro-team@latest/rest/reference/repos/#compare-two-commits
82+
[2]: https://github.com/blend/require-conditional-status-checks/blob/070363af576e7c117f8f331c6cc11c53c047873a/_images/example-run-public.png?raw=true
83+
[3]: https://github.com/blend/require-conditional-status-checks/blob/070363af576e7c117f8f331c6cc11c53c047873a/_images/example-run-ghe.png?raw=true
84+
[4]: https://github.com/blend/require-conditional-status-checks/blob/070363af576e7c117f8f331c6cc11c53c047873a/DEVELOPMENT.md
85+
[5]: https://github.com/blend/require-conditional-status-checks/tree/070363af576e7c117f8f331c6cc11c53c047873a

action.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
# limitations under the License.
1414

1515
---
16-
name: Composite - Conditional Checks for Monorepos
16+
name: Require Conditional Status Checks
1717
description: >
1818
Compose multiple (conditional) checks into a single check based on file paths
1919
in a pull request
@@ -27,7 +27,7 @@ inputs:
2727
required: true
2828
default: 30m
2929
description: >
30-
A maximum duration that the composite action will wait for other actions
30+
A maximum duration that the action will wait for other actions
3131
to complete.
3232
interval:
3333
required: true
@@ -48,7 +48,7 @@ inputs:
4848
(Exactly one of `checks-yaml` and `checks-filename` are required.)
4949
5050
runs:
51-
using: node12
51+
using: node16
5252
main: index.js
5353

5454
branding:

index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ const childProcess = require('child_process')
1616
const os = require('os')
1717
const process = require('process')
1818

19-
const VERSION = '7586da331a1ce003a321cc16ac72319d78c7764b'
19+
const VERSION = '070363af576e7c117f8f331c6cc11c53c047873a'
2020

2121
function chooseBinary() {
2222
const platform = os.platform()
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 commit comments

Comments
 (0)