Repository navigation
fix: confine managed layout destinations before writes - #10
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d44ca494b8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const confined = confineRepositoryDestinations(cwd, targets); | ||
| if (confined.state !== 'confined') { | ||
| throw new Error(`Cannot install managed resources: ${JSON.stringify(confined)}`); |
There was a problem hiding this comment.
Reject directory leaf targets during init
When a managed destination such as .omp-flow/workflow/code/how.md already exists as an ordinary directory, confineRepositoryDestinations accepts it (its generic final-target check permits directories). init --force then passes this preflight, writes earlier plan entries, and only fails at fs.writeFileSync with EISDIR, leaving a partial installation despite the promised before-write rejection. Require file-resource targets to be missing or regular files before entering the deployment loop.
AGENTS.md reference: AGENTS.md:L101-L102
Useful? React with 👍 / 👎.
Correction
Addresses the linked
workflow/codeancestor finding from #9 before npm release..newdestinations and protected-data handling.Linux evidence
.newrejection pass with outside/project content unchanged.Owner calibration
Linux is the requested release target. Existing Windows Sleep alias CI failure is outside this change and is not a release gate. No platform-specific branch or Sleep fix was added. Preflight is not a claim of transactional rollback or immunity to concurrent path replacement. npm publication is still pending actual maintainer authentication.