Look at the currently unstaged changes in git and review them strictly for:
- •Bugs and logic errors
- •Security vulnerabilities
- •Race conditions or concurrency issues
- •Incorrect error handling
- •Edge cases that could cause failures
- •Other similar problems or room for improvements
Obtain the diff to review using this fallback chain:
- •Run
git diff. If this produces output, use it as the diff. - •If empty, run
git diff --cached. If this produces output, use it as the diff. - •If both are empty, run
git diff master...HEADto see all committed changes on the current branch relative to master.
If all three are empty, report that there is nothing to review and stop.
Be specific — reference file names and line numbers. Only flag things that actually matter.