mirror of
https://github.com/qodo-ai/pr-agent.git
synced 2025-07-03 20:30:41 +08:00
Merge pull request #947 from Codium-ai/tr/gitlab_commits
gitlab push_commands
This commit is contained in:
@ -136,7 +136,7 @@ publish_labels = false
|
|||||||
to prevent PR-Agent from publishing labels when running the `describe` tool.
|
to prevent PR-Agent from publishing labels when running the `describe` tool.
|
||||||
|
|
||||||
## GitLab Webhook
|
## GitLab Webhook
|
||||||
After setting up a GitLab webhook, to control which commands will run automatically when a new PR is opened, you can set the `pr_commands` parameter in the configuration file, similar to the GitHub App:
|
After setting up a GitLab webhook, to control which commands will run automatically when a new MR is opened, you can set the `pr_commands` parameter in the configuration file, similar to the GitHub App:
|
||||||
```
|
```
|
||||||
[gitlab]
|
[gitlab]
|
||||||
pr_commands = [
|
pr_commands = [
|
||||||
@ -146,6 +146,20 @@ pr_commands = [
|
|||||||
]
|
]
|
||||||
```
|
```
|
||||||
|
|
||||||
|
the GitLab webhook can also respond to new code that is pushed to an open MR.
|
||||||
|
The configuration toggle `handle_push_trigger` can be used to enable this feature.
|
||||||
|
The configuration parameter `push_commands` defines the list of tools that will be **run automatically** when new code is pushed to the MR.
|
||||||
|
```
|
||||||
|
[gitlab]
|
||||||
|
handle_push_trigger = true
|
||||||
|
push_commands = [
|
||||||
|
"/describe",
|
||||||
|
"/review --pr_reviewer.num_code_suggestions=0 --pr_reviewer.final_update_message=false",
|
||||||
|
]
|
||||||
|
```
|
||||||
|
|
||||||
|
Note that to use the 'handle_push_trigger' feature, you need to give the gitlab webhook also the "Push events" scope.
|
||||||
|
|
||||||
## BitBucket App
|
## BitBucket App
|
||||||
Similar to GitHub app, when running PR-Agent from BitBucket App, the default [configuration file](https://github.com/Codium-ai/pr-agent/blob/main/pr_agent/settings/configuration.toml) from a pre-built docker will be initially loaded.
|
Similar to GitHub app, when running PR-Agent from BitBucket App, the default [configuration file](https://github.com/Codium-ai/pr-agent/blob/main/pr_agent/settings/configuration.toml) from a pre-built docker will be initially loaded.
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user