Integrate CodeRabbit into a GitHub repository that you own
Observe CodeRabbit perform a code review of a pull request that you initiate
Converse with CodeRabbit about the code review
4
>>> Prompt CodeRabbit to generate its own improvements to the pull request
Request code improvements
One of CodeRabbit’s powerful features is its ability to not just identify issues, but also generate the code changes needed to fix them. Instead of manually implementing the suggestions from the review, you can ask CodeRabbit to do it for you. In this step, you’ll use a CodeRabbit command to automatically fix the findings from the review of your Python code.Fix the review findings
Post the following as a new comment on your pull request:Fix comments works only on unresolved CodeRabbit review findings that include fix instructions. If the review left none, CodeRabbit skips the run and opens no pull request. In that case, ask CodeRabbit in the pull request conversation for the change you want, then apply its proposal as described in Confirm and commit prepared changes.
What CodeRabbit does next
After a few moments, CodeRabbit automatically performs the following actions:- Creates a new branch - CodeRabbit generates a new branch based on your
add-utilsbranch - Commits the changes - CodeRabbit applies fixes for the review findings to your
simple_utils.pyfile - Opens a pull request - CodeRabbit creates a new pull request from the new branch back into
add-utils
Review the generated changes
Once CodeRabbit creates the new pull request with the fixes:- Navigate to the new pull request
- Review the generated changes
- Check that each change addresses its review finding
- Merge the changes if they meet your standards
Confirm and commit prepared changes
After CodeRabbit proposes prepared changes in a pull request conversation or inline review thread, confirm the proposal to apply those exact prepared changes to the current branch.- GitHub
- GitLab
In the CodeRabbit-authored general or inline review comment that contains the proposal, select the Commit the changes to this branch checkbox.
Other available commands
CodeRabbit supports many other commands to help you improve your code. For example:@coderabbitai generate unit tests- Create unit tests for your code@coderabbitai fix comments- Apply suggested fixes directly to your current branch@coderabbitai help- See all available commands