-
Notifications
You must be signed in to change notification settings - Fork 2.4k
42 lines (33 loc) · 1.14 KB
/
gemini_summarizer.yml
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
name: Gemini - Summarize Pull Request
on:
pull_request:
types: [opened, edited, synchronize]
permissions:
pull-requests: write
jobs:
comment:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.x'
- name: Install Dependencies
run: pip install --upgrade google-cloud-storage google-cloud-aiplatform PyGithub
- id: 'auth'
uses: 'google-github-actions/auth@v2'
with:
credentials_json: '${{ secrets.GOOGLE_CREDENTIALS }}'
- name: 'Set up Cloud SDK'
uses: 'google-github-actions/setup-gcloud@v2'
- name: 'Use gcloud CLI'
run: 'gcloud info'
- name: Run Script
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GOOGLE_CLOUD_PROJECT_ID: ${{ secrets.GOOGLE_CLOUD_PROJECT_ID }}
PROMPT_FILE: ${{ secrets.SUMMARIZE_PROMPT_FILE }}
BIGQUERY_SUMMARIZE_LOGS_TABLE: ${{ secrets.BIGQUERY_SUMMARIZE_LOGS_TABLE }}
run: python .github/actions/summarizer/gemini_summarize_pr.py