-
Notifications
You must be signed in to change notification settings - Fork 0
/
action.yaml
43 lines (39 loc) · 1.02 KB
/
action.yaml
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
38
39
40
41
42
43
name: "github-ai-review"
description: "review PRs with GPT"
inputs:
PERSONAL_ACCESS_TOKEN:
description: "GitHub token"
required: true
OPENAI_API_KEY:
description: "OpenAI API key"
required: true
branding:
icon: git-pull-request
color: green
runs:
using: "composite"
steps:
- name: checkout
uses: actions/checkout@v3
with:
repository: kentakozuka/github-ai-review
- name: Install Poetry
shell: bash
run: |
pipx install poetry
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.11"
- name: Install Python library
run: |
poetry install --no-root --no-interaction
shell: bash
- name: Run review
shell: bash
run: poetry run python src/main.py
env:
PERSONAL_ACCESS_TOKEN: ${{ inputs.PERSONAL_ACCESS_TOKEN }}
OPENAI_API_KEY: ${{ inputs.OPENAI_API_KEY }}
GITHUB_ISSUE_NUMBER: ${{ github.event.issue.number }}
MODEL_NAME: ${{ inputs.MODEL_NAME }}