diff --git a/CLAUDE.md b/CLAUDE.md index 8946cba0..56b9660d 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -55,6 +55,28 @@ about OtOpcUa changes here — remote/push status, the driver set, the Galaxy da shared-lib consumption, or per-project commands — update the **OtOpcUa entry in `../scadaproj/CLAUDE.md`** in the same change so the index never drifts from this repo. +**The index edit belongs on `scadaproj`'s `main`, and must be pushed.** `scadaproj` is a +separate repo with its own checkout, so committing there inherits whatever branch it +happens to be on — which is usually *not* `main` and is often an unrelated feature branch +with no upstream. That silently drifts the index for as long as that branch stays +unmerged, which is the exact failure the rule above exists to prevent. Do this explicitly: + +```bash +cd ~/Desktop/scadaproj +git rev-parse --abbrev-ref HEAD # note it, to restore afterwards +git stash list # never commit onto a dirty unrelated branch +git checkout main && git pull +# …edit the OtOpcUa entry in CLAUDE.md… +git commit -am "docs(index): " +git push origin main +git checkout - # restore the original branch +``` + +Observed 2026-07-27: the `Sql` poll driver's index entry had sat unpushed on an unrelated +feature branch since 2026-07-24 because it was committed onto the current checkout, so the +index disagreed with reality for three days despite this rule. If you find index commits +stranded on a feature branch, cherry-pick them onto `main` rather than merging that branch. + ## Architecture Overview ### Data Flow