Proposal: visible skillshare/ project directory (#256) - #257
Proposal: visible skillshare/ project directory (#256)#257salmonumbrella wants to merge 1 commit into
skillshare/ project directory (#256)#257Conversation
Project mode is identified only by .skillshare/config.yaml, and trash, backups, logs and audit-rules.yaml anchor to the same hidden directory. The sources option made project content relocatable, but repositories that treat skills as reviewable content still need a hidden directory whose only job is to hold config.yaml. Propose recognizing skillshare/config.yaml as a second project marker, resolved after .skillshare/config.yaml so an existing project never moves and no migration is needed. Refs runkids#256
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a79ac35de0
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
Converting this to a direct implementation PR: #258. Everything in this proposal is folded into that PR body — the problem, the resolution order, the two name collisions, and the back-compat guarantees — so this document would only duplicate it. #258 also carries the working code, tests, docs and schema updates. Issue #256 stays open as the motivation anchor. Sorry for the shuffle. If you would rather review a proposal document first, per CONTRIBUTING, say the word and I will reopen this one and park the implementation. |
Type
proposals/only — see CONTRIBUTING.md)Linked Issue
#256
Summary
This PR adds a feature proposal for recognizing a visible
skillshare/directory as an alternative project marker, alongside the existing.skillshare/.Project mode is identified solely by
.skillshare/config.yaml, andtrash/,backups/,logs/andaudit-rules.yamlanchor to that same hidden directory.sources(#153 / #162) made project content relocatable for repositories that want skills reviewed alongside contributor documentation, but the marker andconfig.yamlstayed hidden — so those repositories end up with a visible skills directory plus a hidden directory whose only job is to hold the config.The proposal resolves the marker in a fixed order,
.skillshare/config.yamlthenskillshare/config.yaml. First hit wins, so.skillshare/stays the default, takes precedence when both exist, and no migration is needed.Notes
This PR only adds a proposal under
proposals/and does not include implementation changes, per CONTRIBUTING.md.I did build the change first so the proposal describes real behaviour rather than a guess, and two findings from that are written into the proposal because they are easy to miss:
BaseDir()is<config-home>/skillshare, so a directory namedskillsharealready means "global config". The two places that infer scope from a config path by directory name (oplog.LogDir/ensureProjectLogGitignore, andisProjectLogConfig) have to exclude the global location by full path instead. Missing this misroutes global operation logs, andTestLogDir_Globalpasses a fixture path that hides the problem unless it declares a config home.internal/auditcannot importinternal/config, sinceconfig→install→auditwould cycle.The working branch is
salmonumbrella:feat/visible-project-dirif it is useful as a reference — 14 non-test files plus a newinternal/projectdirpackage, with tests for hidden-only, visible-only, both-present and neither-present, plus state-directory andinit -p --visiblecoverage.gofmt,go vet ./...andgo build ./...are clean, and the unit packages show no failures beyond the two that already fail onmainoutside the devcontainer (TestCommitSourceFiles_CommitFailureIsReturned,TestGitRootMismatch). Happy to leave it, drop it, or split it however you prefer — the proposal stands on its own.Checklist
make check) — for code changes