Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
aleksei-commmune authored Mar 30, 2023
1 parent e8fe010 commit 4123a71
Showing 1 changed file with 20 additions and 10 deletions.
30 changes: 20 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,25 @@
# github-api
# Approvals counter

To install dependencies:
This action counts amount of approvals of the PR

```bash
bun install
```
## How to use

To run:
You can check that PR has required amount of approvals like this

```bash
bun run index.js
```yml
name: 'Approvals'
description: 'Check that PR has 2 approvals'
outputs:
approved:
description: 'If PR has 2 approvals'
value: ${{steps.approvals.outputs.approvals >= 2}}
runs:
using: 'composite'
steps:
- uses: dayone-jp/approvals@main
id: approvals
env:
GITHUB_TOKEN: "token"
- run: echo ${{steps.approvals.outputs.approvals}}
shell: bash
```

This project was created using `bun init` in bun v0.5.8. [Bun](https://bun.sh) is a fast all-in-one JavaScript runtime.

0 comments on commit 4123a71

Please sign in to comment.