-
Notifications
You must be signed in to change notification settings - Fork 23
37 lines (37 loc) · 1.75 KB
/
Copy pathslash-commands.yml
File metadata and controls
37 lines (37 loc) · 1.75 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: PR Slash Commands
on:
issue_comment:
types: [created]
jobs:
comment-created:
runs-on: ubuntu-latest
steps:
- name: Generate an agent token
id: generate-token
uses: actions/create-github-app-token@v2
with:
app-id: ${{ secrets.KAL_APP_ID }}
private-key: ${{ secrets.KAL_PRIVATE_KEY }}
- uses: actions/checkout@v4
- uses: dagger/dagger-for-github@8.0.0
- name: slash agent
if: github.event.issue.pull_request && contains(github.event.comment.body, '/agent')
run: dagger call pull-request-feedback --github-token GH_TOKEN --issue-id ${{ github.event.issue.number }} --feedback "${{ github.event.comment.body }}"
env:
DAGGER_CLOUD_TOKEN: ${{ secrets.DAGGER_CLOUD_TOKEN }}
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
GH_TOKEN: ${{ steps.generate-token.outputs.token }}
- name: slash review
if: github.event.issue.pull_request && contains(github.event.comment.body, '/review')
run: dagger call pull-request-review --github-token GH_TOKEN --issue-id ${{ github.event.issue.number }}
env:
DAGGER_CLOUD_TOKEN: ${{ secrets.DAGGER_CLOUD_TOKEN }}
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
GH_TOKEN: ${{ steps.generate-token.outputs.token }}
- name: slash develop
if: ${{ !github.event.issue.pull_request && contains(github.event.comment.body, '/develop') }}
run: dagger call develop-pull-request --github-token GH_TOKEN --issue-id ${{ github.event.issue.number }}
env:
DAGGER_CLOUD_TOKEN: ${{ secrets.DAGGER_CLOUD_TOKEN }}
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
GH_TOKEN: ${{ steps.generate-token.outputs.token }}