mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-01-19 17:58:26 +08:00
👷 CI: NoneFlow 添加 reaction 响应提示 (#2677)
This commit is contained in:
parent
6810af1e1d
commit
5c2c1770a2
33
.github/workflows/noneflow.yml
vendored
33
.github/workflows/noneflow.yml
vendored
@ -15,6 +15,39 @@ concurrency:
|
||||
cancel-in-progress: false
|
||||
|
||||
jobs:
|
||||
reaction:
|
||||
runs-on: ubuntu-latest
|
||||
name: reaction
|
||||
if: |
|
||||
(
|
||||
github.event_name == 'issue_comment' &&
|
||||
github.event.action == 'created'
|
||||
) ||
|
||||
(
|
||||
github.event_name == 'issues' &&
|
||||
github.event.action == 'opened'
|
||||
)
|
||||
steps:
|
||||
- name: Generate token
|
||||
id: generate-token
|
||||
uses: tibdex/github-app-token@v2
|
||||
with:
|
||||
app_id: ${{ secrets.APP_ID }}
|
||||
private_key: ${{ secrets.APP_KEY }}
|
||||
|
||||
- name: Reaction on issue
|
||||
if: github.event_name == 'issues'
|
||||
run: |
|
||||
gh api --method POST /repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/reactions -f "content=rocket"
|
||||
env:
|
||||
GH_TOKEN: ${{ steps.generate-token.outputs.token }}
|
||||
|
||||
- name: Reaction on issue comment
|
||||
if: github.event_name == 'issue_comment'
|
||||
run: |
|
||||
gh api --method POST /repos/${{ github.repository }}/issues/comments/${{ github.event.comment.id }}/reactions -f "content=rocket"
|
||||
env:
|
||||
GH_TOKEN: ${{ steps.generate-token.outputs.token }}
|
||||
plugin_test:
|
||||
runs-on: ubuntu-latest
|
||||
name: nonebot2 plugin test
|
||||
|
Loading…
Reference in New Issue
Block a user