Skip to content

Commit 256593e

Browse files
authored
Merge pull request #392 from MannLabs/code-review
add code review
2 parents d30206a + f9ba722 commit 256593e

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

.github/workflows/code_review.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Create an automated AI code review that runs when a PR is labeled with 'code-review'
2+
name: code-review
3+
4+
on:
5+
pull_request:
6+
types: [ labeled ]
7+
8+
jobs:
9+
get-code-review:
10+
runs-on: ubuntu-latest
11+
if: contains(github.event.pull_request.labels.*.name, 'code-review') # || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
12+
permissions:
13+
contents: read
14+
pull-requests: write
15+
steps:
16+
- uses: MannLabs/alphashared/actions/code-review@v1
17+
continue-on-error: true
18+
with:
19+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
20+
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
21+
CODE_REVIEW_PROMPT: ${{ secrets.CODE_REVIEW_PROMPT }}
22+
CODE_REVIEW_SYSTEM_MESSAGE: ${{ secrets.CODE_REVIEW_SYSTEM_MESSAGE }}
23+
GITHUB_EVENT_NUMBER: ${{ github.event.number }}
24+
EXCLUDED_EXTENSIONS: "ipynb;js"

0 commit comments

Comments
 (0)