-
Notifications
You must be signed in to change notification settings - Fork 151
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
83a07ec
commit a7b20b3
Showing
1 changed file
with
16 additions
and
19 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 |
---|---|---|
|
@@ -7,28 +7,25 @@ on: | |
jobs: | ||
respond: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
issues: write | ||
steps: | ||
- name: Respond to new issues | ||
uses: actions/github-script@v7 | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
script: | | ||
const issueNumber = context.issue.number; | ||
const issueAuthor = context.payload.issue.user.login; | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
|
||
const commentBody = ` | ||
Hi @${issueAuthor}, thank you for opening this issue! | ||
- name: Install GitHub CLI | ||
run: sudo apt-get install gh | ||
|
||
We appreciate your effort in reporting this. Our team will review it and get back to you soon. | ||
If you have any additional details or updates, feel free to add them to this issue. | ||
- name: Respond to new issues | ||
run: gh issue comment ${{ github.event.issue.number }} --body "$BODY" | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
BODY: | | ||
Hi @${{ github.event.issue.user.login }}, thank you for opening this issue! | ||
**Note:** If this is a serious security issue that could impact the security of Safety CLI users, please email [email protected] immediately. | ||
We appreciate your effort in reporting this. Our team will review it and get back to you soon. | ||
If you have any additional details or updates, feel free to add them to this issue. | ||
Thank you for contributing to Safety CLI! | ||
`; | ||
**Note:** If this is a serious security issue that could impact the security of Safety CLI users, please email [email protected] immediately. | ||
await github.issues.createComment({ | ||
...context.repo, | ||
issue_number: issueNumber, | ||
body: commentBody | ||
}); | ||
Thank you for contributing to Safety CLI! |