From 4a5310e2a17d6f1dddf5b64c57b2db65e36f26c9 Mon Sep 17 00:00:00 2001
From: Itamar Friedman <108689937+coditamar@users.noreply.github.com>
Date: Wed, 6 Sep 2023 10:46:25 +0300
Subject: [PATCH 1/3] Update README.md
---
README.md | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/README.md b/README.md
index eff850e6..ade40209 100644
--- a/README.md
+++ b/README.md
@@ -15,20 +15,20 @@ Making pull requests less painful with an AI agent
-CodiumAI `PR-Agent` is an open-source tool aiming to help developers review pull requests faster and more efficiently. It automatically analyzes the pull request and can provide several types of PR feedback:
+CodiumAI `PR-Agent` is an open-source tool aiming to help developers review pull requests faster and more efficiently. It automatically analyzes the pull request and can provide several types of commands:
-**Auto Description (/describe)**: Automatically generating [PR description](https://github.com/Codium-ai/pr-agent/pull/229#issue-1860711415) - title, type, summary, code walkthrough and labels.
+‣ **Auto Description (`/describe`)**: Automatically generating [PR description](https://github.com/Codium-ai/pr-agent/pull/229#issue-1860711415) - title, type, summary, code walkthrough and labels.
\
-**Auto Review (/review)**: [Adjustable feedback](https://github.com/Codium-ai/pr-agent/pull/229#issuecomment-1695022908) about the PR main theme, type, relevant tests, security issues, score, and various suggestions for the PR content.
+‣ **Auto Review (`/review`)**: [Adjustable feedback](https://github.com/Codium-ai/pr-agent/pull/229#issuecomment-1695022908) about the PR main theme, type, relevant tests, security issues, score, and various suggestions for the PR content.
\
-**Question Answering (/ask ...)**: Answering [free-text questions](https://github.com/Codium-ai/pr-agent/pull/229#issuecomment-1695021332) about the PR.
+‣ **Question Answering (`/ask ...`)**: Answering [free-text questions](https://github.com/Codium-ai/pr-agent/pull/229#issuecomment-1695021332) about the PR.
\
-**Code Suggestions (/improve)**: [Committable code suggestions](https://github.com/Codium-ai/pr-agent/pull/229#discussion_r1306919276) for improving the PR.
+‣ **Code Suggestions (`/improve`)**: [Committable code suggestions](https://github.com/Codium-ai/pr-agent/pull/229#discussion_r1306919276) for improving the PR.
\
-**Update Changelog (/update_changelog)**: Automatically updating the CHANGELOG.md file with the [PR changes](https://github.com/Codium-ai/pr-agent/pull/168#discussion_r1282077645).
+‣ **Update Changelog (`/update_changelog`)**: Automatically updating the CHANGELOG.md file with the [PR changes](https://github.com/Codium-ai/pr-agent/pull/168#discussion_r1282077645).
-See the [usage guide](./Usage.md) for instructions how to run the different tools from [CLI](./Usage.md#working-from-a-local-repo-cli), or by [online usage](./Usage.md#online-usage).
+See the [usage guide](./Usage.md) for instructions how to run the different tools from [CLI](./Usage.md#working-from-a-local-repo-cli), or by [online usage](./Usage.md#online-usage), as well as additional details on optional commands and configurations.
Example results:
@@ -199,4 +199,4 @@ Here are some advantages of PR-Agent:
- [Aider - GPT powered coding in your terminal](https://github.com/paul-gauthier/aider)
- [openai-pr-reviewer](https://github.com/coderabbitai/openai-pr-reviewer)
- [CodeReview BOT](https://github.com/anc95/ChatGPT-CodeReview)
-- [AI-Maintainer](https://github.com/merwanehamadi/AI-Maintainer)
\ No newline at end of file
+- [AI-Maintainer](https://github.com/merwanehamadi/AI-Maintainer)
From e486addb8f6043a7c5e720fdd15a153fa7be32cb Mon Sep 17 00:00:00 2001
From: Itamar Friedman <108689937+coditamar@users.noreply.github.com>
Date: Wed, 6 Sep 2023 11:28:19 +0300
Subject: [PATCH 2/3] Update INSTALL.md
minor clarification to Method 8 GitLab
---
INSTALL.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/INSTALL.md b/INSTALL.md
index 285b3f14..13b13b1f 100644
--- a/INSTALL.md
+++ b/INSTALL.md
@@ -354,7 +354,7 @@ PYTHONPATH="/PATH/TO/PROJECTS/pr-agent" python pr_agent/cli.py \
```
WEBHOOK_SECRET=$(python -c "import secrets; print(secrets.token_hex(10))")
```
-3. Follow the instructions to build the Docker image, setup a secrets file and deploy on your own server from [Method 5](#method-5-run-as-a-github-app).
+3. Follow the instructions to build the Docker image, setup a secrets file and deploy on your own server from [Method 5](#method-5-run-as-a-github-app) steps 4-7.
4. In the secrets file, fill in the following:
- Your OpenAI key.
- In the [gitlab] section, fill in personal_access_token and shared_secret. The access token can be a personal access token, or a group or project access token.
@@ -370,4 +370,4 @@ If you're testing your codium/pr-agent server, and need to see if calls were mad
You can do this by setting `litellm_debugger=true` in configuration.toml. Your Logs will be viewable in real-time @ `admin.litellm.ai/`. Set your email in the `.secrets.toml` under 'user_email'.
-
\ No newline at end of file
+
From 753ea3e44c6ada44cd2eda02ea7e46bc5522a5b0 Mon Sep 17 00:00:00 2001
From: Ori Kotek
Date: Wed, 6 Sep 2023 11:35:41 +0300
Subject: [PATCH 3/3] Update INSTALL.md
---
INSTALL.md | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/INSTALL.md b/INSTALL.md
index 13b13b1f..4f39da89 100644
--- a/INSTALL.md
+++ b/INSTALL.md
@@ -24,9 +24,15 @@ To request a review for a PR, or ask a question about a PR, you can run directly
1. To request a review for a PR, run the following command:
+For GitHub:
```
docker run --rm -it -e OPENAI.KEY= -e GITHUB.USER_TOKEN= codiumai/pr-agent --pr_url review
```
+For GitLab:
+```
+docker run --rm -it -e OPENAI.KEY= -e CONFIG.GIT_PROVIDER=gitlab -e GITLAB.PERSONAL_ACCESS_TOKEN= codiumai/pr-agent --pr_url review
+```
+For other git providers, update CONFIG.GIT_PROVIDER accordingly, and check the `pr_agent/settings/.secrets_template.toml` file for the environment variables expected names and values.
2. To ask a question about a PR, run the following command: