-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: add custom triage action, label-author into triage workflow
- Loading branch information
Showing
15 changed files
with
80,549 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
module.exports = { | ||
env: { | ||
es6: true, | ||
node: true, | ||
}, | ||
extends: ['eslint:recommended', 'plugin:@typescript-eslint/eslint-recommended'], | ||
parser: '@typescript-eslint/parser', | ||
parserOptions: { | ||
ecmaVersion: 2018, | ||
sourceType: 'module', | ||
}, | ||
plugins: ['@typescript-eslint'], | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
module.exports = { | ||
printWidth: 100, | ||
parser: 'typescript', | ||
semi: false, | ||
singleQuote: true, | ||
trailingComma: 'all', | ||
arrowParens: 'avoid', | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
MIT License | ||
|
||
Copyright (c) 2024 Payload <[email protected]>. All modification and additions are copyright of Payload. | ||
|
||
--- | ||
|
||
Original license: | ||
ISC License | ||
|
||
Copyright (c) 2023, Balázs Orbán | ||
|
||
Permission to use, copy, modify, and/or distribute this software for any | ||
purpose with or without fee is hereby granted, provided that the above | ||
copyright notice and this permission notice appear in all copies. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Triage | ||
|
||
Modified version of https://github.com/balazsorban44/nissuer | ||
|
||
## Modifications | ||
|
||
- Port to TypeScript | ||
- Remove issue locking | ||
- Remove reproduction blocklist | ||
- Uses `@vercel/ncc` for packaging | ||
|
||
## Development | ||
|
||
> [!IMPORTANT] | ||
> Whenever a modification is made to the action, the action built to `dist` must be committed to the repository. | ||
This is done by running: | ||
|
||
```sh | ||
pnpm build | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: Triage | ||
description: Initial triage for issues | ||
|
||
inputs: | ||
reproduction-comment: | ||
description: 'Either a string or a path to a .md file inside the repository. Example: ".github/invalid-reproduction.md"' | ||
default: '.github/invalid-reproduction.md' | ||
reproduction-hosts: | ||
description: 'Comma-separated list of hostnames that are allowed for reproductions. Example: "github.com,codesandbox.io"' | ||
default: github.com | ||
reproduction-invalid-label: | ||
description: 'Label to apply to issues without a valid reproduction. Example: "invalid-reproduction"' | ||
default: 'invalid-reproduction' | ||
reproduction-issue-labels: | ||
description: 'Comma-separated list of issue labels. If configured, only verify reproduction URLs of issues with one of these labels present. Adding a comma at the end will handle non-labeled issues as invalid. Example: "bug,", will consider issues with the label "bug" or no label.' | ||
default: '' | ||
reproduction-link-section: | ||
description: 'A regular expression string with "(.*)" matching a valid URL in the issue body. The result is trimmed. Example: "### Link to reproduction(.*)### To reproduce"' | ||
default: '### Link to reproduction(.*)### To reproduce' | ||
tag-only: | ||
description: Log and tag only. Do not perform closing or commenting actions. | ||
default: false | ||
|
||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Checkout code | ||
if: ${{ github.event_name != 'pull_request' }} | ||
uses: actions/checkout@v4 | ||
- name: Run action | ||
run: node ${{ github.action_path }}/dist/index.js | ||
shell: sh | ||
# https://github.com/actions/runner/issues/665#issuecomment-676581170 | ||
env: | ||
"INPUT_REPRODUCTION_COMMENT": ${{inputs.reproduction-comment}} | ||
"INPUT_REPRODUCTION_HOSTS": ${{inputs.reproduction-hosts}} | ||
"INPUT_REPRODUCTION_INVALID_LABEL": ${{inputs.reproduction-invalid-label}} | ||
"INPUT_REPRODUCTION_ISSUE_LABELS": ${{inputs.reproduction-issue-labels}} | ||
"INPUT_REPRODUCTION_LINK_SECTION": ${{inputs.reproduction-link-section}} | ||
"INPUT_TAG_ONLY": ${{inputs.tag-only}} |
Oops, something went wrong.