Event 76 · CP-SYMLINK-RESTORE-01 Part A · scripts/restore-private-symlinks.sh#33
Merged
Event 76 · CP-SYMLINK-RESTORE-01 Part A · scripts/restore-private-symlinks.sh#33
Conversation
…itignored canonical-path symlinks (Event 76) CP-SYMLINK-RESTORE-01 Part A (v1.0.1 polish mini-batch CP #2). After Events 65/66/71 privatized 18 docs to ~/episteme-private/ with relative symlinks at gitignored canonical paths, any branch switch or fresh clone wipes the local symlinks. Operator was forced to manually re-ln -sf each path; observed mid-Event-74 when filter-repo recovery surfaced the missing-symlinks state. This script walks the privatize list (4 Event-65 forward-vision docs + 10 Event-66 Tier-1+2 docs + 4 Event-71 operator-profile canonicals = 18 total), validates each private target exists, and creates symlinks with the correct relative path per directory depth (2 levels for docs/; 4 levels for core/memory/global/). - Idempotent: skips symlinks already pointing at the correct target - Reports: restored / already-correct / missing-private counts - Exit codes: 0 = clean, 1 = no private dir, 2 = some targets missing - Dogfooded locally: 18/18 resolve correctly, idempotency verified Soak-protected surfaces touched: ZERO (scripts/-tier only). Part B (SessionStart hook integration in core/hooks/session_context.py to auto-detect + auto-run this script) deferred to a later Event. Splitting Part A and Part B keeps each Event's scope minimal.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Second v1.0.1 polish mini-batch CP shipped. Adds
scripts/restore-private-symlinks.sh— a small bash utility that recreates the 18 gitignored canonical-path symlinks pointing into~/episteme-private/.Trigger. After Events 65/66/71 privatized 18 docs with relative symlinks at gitignored canonical paths, any branch switch or fresh clone wipes the local symlinks because they're not in git history. The friction surfaced mid-Event-74 when
git filter-reporecovery left the working tree without symlinks at canonical paths — operator had to manuallyln -sfeach one. This script closes that loop.What this ships
scripts/restore-private-symlinks.sh(NEW, executable, 122 lines).Walks the embedded privatize list:
For each path, verifies the private target exists in
$HOME/episteme-private/, computes the correct relative-path prefix (2 levels fordocs/, 4 levels forcore/memory/global/), and runsln -sfto create or refresh the symlink.Properties:
0clean,1no private dir (fork users),2some private targets missing.What's deferred
Part B of the CP —
SessionStarthook integration incore/hooks/session_context.pythat auto-detects missing symlinks (where private targets exist) and prompts to run this script. Estimated ~1 hour. Touchescore/hooks/*(post-soak; allowed). Deferred to a later Event for tight scope per the operator's preference for cognitively-bounded sessions.Verification
ls -la+headcontent read)docs/=../..;core/memory/global/=../../../..)Soak-invariant
ZERO touches to
kernel/*/core/hooks/*/core/blueprints/*/src/episteme/*/tests/*/templates/*/labs/*. Single new file underscripts/(operator-tooling tier).v1.0.1 polish queue post-Event-76
Cross-references
~/episteme-private/docs/cp-v1.0.1-polish.md§ CP-SYMLINK-RESTORE-01~/episteme-private/docs/PROGRESS.mdEvent 74 entry — filter-repo recovery left missing symlinks).gitignoreEvent 65 / Event 66 / Event 71 sections~/episteme-private/docs/PROGRESS.mdEvent 76 entry (private)