Add example workflow for PR review with session caching#877
Add example workflow for PR review with session caching#877ranyhb wants to merge 1 commit intoanthropics:mainfrom
Conversation
|
@claude what do u think ? |
|
@ashwin-ant what do u think? already tested and working |
|
@ashwin-ant wdyt? |
|
@ranyhb this looks interesting! How does Claude know what session it's working from though if it's only passed |
|
@benkingcode I’m generally following Claude Code’s workflow. When you’re working in a PR, you only have a single session per project (one project under Claude/projects), which is why I save the cache. Using the --continue flag just restores the last session—and in our case, there’s only one. |
|
i synced my fork, can u re run it the tests, please? |
|
@ashwin-ant any updates? :) |
|
@ashwin-ant :) |
|
@ashwin-ant any update? |
1 similar comment
|
@ashwin-ant any update? |
|
@ashwin-ant |
|
@ashwin-ant any change to merge that today ? |
Overview
Adds a new workflow example (
pr-review-with-caching.yml) that demonstrates how to use session caching with commit tracking to enable incremental PR reviews.Key Features
~/.claude/projects) per PR and commit using GitHub Actions cache.last-reviewed-commitfilePROMPT_FULL: Comprehensive prompt for first reviewPROMPT_SIMPLE: Incremental prompt for subsequent reviews--continueflag when previous session existsgit diff,git log, andgit cat-filefor analyzing changesHow It Works
First Commit (Full Review):
PROMPT_FULLwith comprehensive review instructions.last-reviewed-commitSubsequent Commits (Incremental Review):
.last-reviewed-committo get previous commit SHAPROMPT_SIMPLEwith{LAST_COMMIT}variable injected--continueflag to resume from previous sessionBenefits
Testing
This workflow can be tested by: