Hacker News new | ask | show | jobs
Show HN: Zsh helpers for LLM Git diff review (github.com)
1 points by ackdesha 106 days ago
= Pipe any Git diff range into Claude Code CLI =

Review the last commit of your feature branch:

  claudiff "HEAD^..HEAD" "code review"
Review the last 3 commits of your feature branch:

  claudiff "HEAD~3..HEAD" "produce gherkin acceptance criteria"
Review working tree changes (uncommitted):

  claudiff HEAD "Suggest code cleanups"
Review staged changes:

  claudiff --staged "review as if you were Linus Torvalds"
Review a pull request branch before merging:

  claudiff "origin/main..HEAD" "review as if you were Anders Hejlsberg"
Since last tag:

  claudiff "$(git describe --tags --abbrev=0)..HEAD" "Generate release notes"
Or do the same as above with Github Copilot CLI using `copdiff` instead of `claudiff`