fix: copied from docs
This commit is contained in:
parent
47a867a537
commit
4a2c8895af
43
.github/workflows/qodo_review.yml
vendored
43
.github/workflows/qodo_review.yml
vendored
@ -1,37 +1,26 @@
|
|||||||
name: Qodo PR Agent (Gemini)
|
name: PR Agent (Gemini)
|
||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
types: [opened, reopened, synchronize]
|
types: [opened, reopened, ready_for_review]
|
||||||
# Allows you to trigger commands like /review or /improve by commenting on the PR
|
|
||||||
issue_comment:
|
issue_comment:
|
||||||
types: [created]
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
pr_agent_job:
|
pr_agent_job:
|
||||||
# Make sure this matches the label of your self-hosted Gitea act_runner
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
name: Run PR Agent
|
|
||||||
# Prevent infinite loops if the bot comments on its own reviews
|
|
||||||
if: ${{ github.event.sender.type != 'Bot' }}
|
if: ${{ github.event.sender.type != 'Bot' }}
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
|
issues: write
|
||||||
|
pull-requests: write
|
||||||
|
contents: write
|
||||||
steps:
|
steps:
|
||||||
- name: Qodo PR Agent
|
- name: PR Agent action step
|
||||||
uses: Codium-ai/pr-agent@main
|
uses: qodo-ai/pr-agent@main
|
||||||
env:
|
env:
|
||||||
# --- 1. Gitea Configuration ---
|
GITHUB_TOKEN: ${{ secrets.GIT_TOKEN }}
|
||||||
CONFIG__GIT_PROVIDER: "gitea"
|
config.model: "gemini/gemini-1.5-flash"
|
||||||
|
config.fallback_models: '["gemini/gemini-1.5-flash"]'
|
||||||
# Automatically pulls your self-hosted Gitea URL
|
GOOGLE_AI_STUDIO.GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
|
||||||
GITEA__URL: ${{ github.server_url }}
|
github_action_config.auto_review: "true"
|
||||||
|
github_action_config.auto_describe: "true"
|
||||||
# Gitea Actions automatically provide this token for repository access
|
github_action_config.auto_improve: "true"
|
||||||
GITEA__PERSONAL_ACCESS_TOKEN: ${{ secrets.GIT_TOKEN }}
|
|
||||||
|
|
||||||
# --- 2. Gemini Configuration ---
|
|
||||||
# Specify the Gemini model (e.g., gemini-1.5-pro or gemini-1.5-flash)
|
|
||||||
CONFIG__MODEL: "gemini/gemini-1.5-pro"
|
|
||||||
CONFIG__FALLBACK_MODELS: '["gemini/gemini-1.5-flash"]'
|
|
||||||
|
|
||||||
# Provide your API key from Gitea Secrets
|
|
||||||
GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user