I already have a large codebase where we regularly perform pull requests (PRs). What’s the simplest way to ask Cursor how to review a PR in the context of the main branch? Would it be sufficient to just copy and paste the changes exported from Git or is there a cleaner way?
I was looking for the same thing and was bout to build a pipeline for PR review, but that is actually not necessary. In Cursor Chat, you can use @PR to reference it and add some instructions that serve your needs.
Here’s how I do it:
@PR (Diff with Main Branch)
Please analyze the code changes and provide the following information:
1. **Intent and Purpose**: Summarize the goal of the changes. Explain what functionality or behavior the changes aim to introduce, modify, or fix.
2. **Potential Issues**: Identify any possible problems the changes might introduce, such as:
- Bugs or unintended side effects.
- Performance concerns.
- Code quality issues (e.g., readability, maintainability, scalability).
- Violations of best practices or standards.
3. **Suggestions for Improvement**: Recommend any improvements or alternative approaches that could enhance the code.