fix(skills/update-stack): switch drift gate scan to git diff (catches missing-locally case)#4244
Conversation
… missing-locally case) Replace `git ls-files` iteration (locally-present files only) with `git diff --name-only devkit-vue/master HEAD` (bidirectional). Adds a second BLOCK arm for files present upstream but absent locally — the previous scan silently skipped deleted stack files. Closes #4233
|
Warning Review limit reached
More reviews will be available in 59 minutes and 57 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
This PR updates the /update-stack “3ter. Block on drift” gate in .claude/skills/update-stack/SKILL.md to source its scan list from git diff --name-only devkit-vue/master HEAD instead of iterating locally-present files via git ls-files, with the goal of also catching “present upstream but missing locally” cases.
Changes:
- Switches the drift scan input list from
git ls-files …togit diff --name-only devkit-vue/master HEAD -- …to include upstream-vs-local deletions. - Adds an explicit BLOCK branch for “missing locally (was on upstream)” with a suggested restore command.
- Updates the documented Rules to explain why
git diffwas chosen.
| done < <(git diff --name-only devkit-vue/master HEAD -- src/modules src/lib src/config 2>/dev/null \ | ||
| | grep -vE "/(tests|__tests__)/" | grep -vE "\.(test|spec)\.(js|jsx|ts|tsx|vue)$") |
Summary
git ls-files src/modules src/lib src/configiteration (locally-present files only) withgit diff --name-only devkit-vue/master HEAD(bidirectional diff)BLOCKarm: files present upstream but absent locally →BLOCK: missing locally (was on upstream)with a restore hintgit diffwas chosen overgit ls-filesRoot cause
The old gate iterated
git ls-fileswhich only enumerates files that exist in the working tree. A file deleted from a downstream (but still in upstream) was silently skipped — the gate could never detect the "missing locally" case.Test plan
bash -c '...'on the gate block — exits 0 on clean tree3ter: no drift — OKon a clean downstream after/update-stackmissing locallymessageCloses #4233