Skip to content
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

feat(output): print output parameters #458

Merged
merged 13 commits into from Jun 3, 2021
2 changes: 2 additions & 0 deletions .github/pull_request_template.md
@@ -1,5 +1,7 @@
<!-- List the change(s) you're making with this PR. -->

## Changes

- [x] ...

## Context
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/test.yml
Expand Up @@ -19,7 +19,10 @@ jobs:
steps:
- uses: actions/checkout@v2
- uses: ./
id: stale
with:
stale-issue-message: 'This issue is stale'
stale-pr-message: 'This PR is stale'
debug-only: true
- name: print outputs
run: echo ${{ join(steps.stale.outputs.*, ',') }}
17 changes: 12 additions & 5 deletions README.md
Expand Up @@ -4,7 +4,7 @@ Warns and then closes issues and PRs that have had no activity for a specified a

## All options

### List of options
### List of input options

Every argument is optional.

Expand All @@ -13,10 +13,10 @@ Every argument is optional.
| `repo-token` | PAT (Personal Access Token) for authorizing the repository.<br>_Defaults to **${{ github.token }}**_. |
| `days-before-stale` | Idle number of days before marking an issue/PR as stale.<br>_Defaults to **60**_. |
| `days-before-issue-stale` | Idle number of days before marking an issue as stale.<br>_Override `days-before-stale`_. |
| `days-before-pr-stale` | Idle number of days before marking a PR as stale.<br>_Override `days-before-stale`_. |
| `days-before-close` | Idle number of days before closing a stale issue/PR.<br>_Defaults to **7**_. |
| `days-before-issue-close` | Idle number of days before closing a stale issue.<br>_Override `days-before-close`_. |
| `days-before-pr-close` | Idle number of days before closing a stale PR.<br>_Override `days-before-close`_. |
| `days-before-pr-stale` | Idle number of days before marking a PR as stale.<br>_Override `days-before-stale`_. |
| `days-before-close` | Idle number of days before closing a stale issue/PR.<br>_Defaults to **7**_. |
| `days-before-issue-close` | Idle number of days before closing a stale issue.<br>_Override `days-before-close`_. |
| `days-before-pr-close` | Idle number of days before closing a stale PR.<br>_Override `days-before-close`_. |
| `stale-issue-message` | Message to post on the stale issue. |
| `stale-pr-message` | Message to post on the stale PR. |
| `close-issue-message` | Message to post on the stale issue while closing it. |
Expand Down Expand Up @@ -59,6 +59,13 @@ Every argument is optional.
| `exempt-all-pr-assignees` | Exempt all PRs with assignees from being marked as stale.<br>_Override `exempt-all-assignees`_. |
| `enable-statistics` | Display some statistics at the end of the logs regarding the stale workflow.<br>Only when the logs are enabled.<br>_Defaults to **true**_. |

### List of output options

| Output | Description |
| ------------- | -------------------------- |
| staled-issues | List of all staled issues. |
flaxel marked this conversation as resolved.
Show resolved Hide resolved
| closed-issues | List of all closed issues. |

### Detailed options

#### operations-per-run
Expand Down
5 changes: 5 additions & 0 deletions action.yml
Expand Up @@ -176,6 +176,11 @@ inputs:
description: 'Display some statistics at the end regarding the stale workflow (only when the logs are enabled).'
default: 'true'
required: false
outputs:
closed-issues:
description: 'List of all closed issues.'
staled-issues:
description: 'List of all staled issues.'
runs:
using: 'node12'
main: 'dist/index.js'