agentsclimarketplace

Canonical repo structure

Skill jacob-balslev/skills/skills/software-engineering-method/canonical-repo-structure

Public Agent Skills library exported from skill-graph. Install: npx skills add jacob-balslev/skills

Install
npx -y skills add jacob-balslev/skills --skill canonical-repo-structure

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Use when organizing or cleaning a project/repository so every script, command, prompt, doc, generated artifact, compatibility shim, and legacy path has one canonical home under version control. Covers owner selection, repo-boundary verification, generated-vs-authored separation, duplicate implementation cleanup, compatibility-shim registration, delete-to-git-history discipline, timestamped changelog explanations, and path-limited commits in the owning repo. Do NOT use for ordinary branching/rebase/tag strategy alone (use `version-control`), behavior-preserving code restructuring alone (use `refactor`), documentation-sync routing alone (use `doc-updater`), or controlled category taxonomy design alone (use `taxonomy-design`).

The file declares its own license as MIT. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.

SKILL.md

18.6 KB, ~2.0k tokens by cl100k_base, as published. Nobody here has run it

Canonical Repo Structure

Concept of the skill

A repository is a map of ownership. Each artifact has one canonical source, zero or more generated projections, and at most one compatibility path per runtime that truly needs the old entrypoint.

Coverage

  • Choosing the owning repo and canonical path before creating, moving, or deleting scripts, commands, prompts, docs, generated artifacts, skills, and compatibility entrypoints
  • Separating authored source from generated projections so agents edit the real source and regenerate the output
  • Preventing duplicate implementations: update the owner, convert one necessary compatibility path into a thin registered shim, or remove the extra path
  • Deciding whether a legacy artifact is live, deprecated, confirmed dead, generated, historical, or a runtime-required compatibility entrypoint
  • Deleting confirmed-dead code to git history instead of preserving _archive/, .legacy, commented-out blocks, or "kept just in case" copies
  • Recording deprecation/removal reasons in the owning changelog with a date plus time-of-day when the owning repo requires timestamped prose
  • Updating live references after moves/deletions while leaving frozen historical records accurate
  • Committing path-limited in the repo that owns the changed files

Philosophy of the skill

A repo is not just storage. It is an operating map for future agents. When one command body lives in three places, no reader knows which behavior is real. When generated output is hand-edited, the next generation run destroys the change. When dead code is moved into _archive/, every grep, router, audit, and cold-start reader has to rediscover that the file is dead.

Canonical organization is therefore a reliability feature. The correct tree is not the smallest tree; it is the tree where source, generated output, compatibility paths, and historical records are visibly different. Preserve live capability, preserve historical recovery in git, and remove dead weight from the live working tree.

Workflow

  1. Identify the artifact and owning repo. Run git rev-parse --show-toplevel from the path you will touch. For nested repos, commit in the nearest owning repo, not in the parent that happens to list or ignore the path.
  2. Find existing owners before adding a new path. Search names, commands, imports, package scripts, docs, and registries. If an owner exists, update that owner instead of copying it.
  3. Classify the path.
    • Authored source: human-edited truth. Keep one canonical file.
    • Generated projection: regenerated from source. Do not hand-edit; update the generator or source.
    • Compatibility path: runtime-required entrypoint that delegates to canonical source. Register it and keep it thin.
    • Frozen historical record: changelog, ADR, report, or archived analysis that describes past state. Do not rewrite it to pretend history changed.
    • Confirmed-dead artifact: no live consumer and no current contract. Remove it from the tree.
  4. Choose the canonical home from the owner map. Use the project AGENTS.md, implementation-ownership registry, document-routing table, package entrypoints, and runtime constraints. If a runtime can only read a specific path, leave a minimal shim there and put the logic in the canonical project-owned path.
  5. Verify before deprecating or deleting. Grep live code, docs, scripts, package files, command manifests, and routing registries. Exclude frozen historical records from the live-dependency decision. A historical mention proves the artifact existed; it does not prove the artifact is still live.
  6. Remove confirmed-dead implementation code to git history. Use git rm for tracked files. Do not move dead code to an archive folder or leave commented-out code. Record what was removed, why it was dead, the replacement or shim target if one exists, and a recovery command such as git log --all --oneline -- <path> followed by git checkout <sha>^ -- <path>.
  7. Update live references in the same change. Grep *.md, *.sh, *.json, package scripts, command manifests, and owning docs for the old path/name. Fix live references; leave changelog/ADR/report mentions alone unless they are themselves wrong.
  8. Commit only the owned paths. Use path-limited commits in the repo that owns the files. If multiple repos changed, create separate commits per repo.

Placement Rules

Artifact kindCanonical homeCompatibility rule
Project-specific system codeOwning project repo, usually under lib/, scripts/, bin/, or the project-specific command/prompt directoryLeave a shim only when a runtime mechanically resolves from a fixed path
Individual skill contentskills/skills/<subject>/<skill-name>/SKILL.md plus sibling artifactsDo not author skill content in generated marketplace exports
Skill Graph schema, audit, prompt, and tooling system codeskill-graph/ paths owned by the Skill Graph projectRuntime command files outside skill-graph/ carry only pointer/delegation text when required
Generated manifests, indexes, exports, and status filesGenerated by their named scriptRegenerate from source; do not patch by hand unless the generator is the thing being fixed
Documentation truthThe owning doc named by the routing tableIndexes and pointer files link to the owner; they do not duplicate the body
Removed or superseded codeGit history, changelog explanation, and optional removed-path registryNo _archive/, .legacy, or commented-out implementation body in the live tree

Keep, Shim, Or Remove

EvidenceAction
Live imports, package scripts, runtime command resolution, tests, or documented user entrypoint still call the pathKeep it or convert it into a thin shim after moving logic
Path exists only for a runtime that cannot resolve the canonical locationKeep a registered shim with no business logic and a documented removal condition
Path is generated from a source fileDelete manual edits, fix source/generator, and regenerate
Only frozen historical records mention itRemove the live artifact and leave the historical records unchanged
No live references, job complete, superseded owner wired, or one-shot migration finishedgit rm, update changelog/registry as required, and record recovery command
You cannot prove whether it is liveKeep it for now and flag the uncertainty; do not guess-delete

Deprecation And Removal Discipline

  • Deprecation is caused by a replacement, direction change, or completed migration. It is not caused by age alone.
  • The live tree carries current source, current shims, current generated outputs, and current docs. Prior implementations live in git history.
  • A deprecated compatibility path that stays callable must be registered with its canonical target, status, removal condition, and required delegation/import target.
  • A removed implementation path should be listed in the owning removed-path registry when such a registry exists, so it is not silently resurrected.
  • Changelog entries for deprecation/removal name the artifact, why it changed, the replacement or shim target, and how to recover it from git.
  • When the owning project requires timestamped prose, use date plus time-of-day, for example 2026-06-07T14:32+02:00, not just 2026-06-07.

Verification

  • The nearest git repo owner was verified for every changed path
  • Existing owners and duplicate paths were searched before adding a new artifact
  • Authored source and generated projections are visibly separated
  • Any compatibility path is registered, minimal, and delegates to the canonical path
  • Confirmed-dead code was removed from the live tree rather than archived in-place
  • Live references to moved/deleted paths were updated; frozen historical references were left intact unless wrong
  • The owning changelog or lifecycle registry records deprecation/removal reason and recovery path when required
  • Path-limited commits were used in the owning repo, with separate commits for separate repos

Do NOT Use When

Use insteadWhen
version-controlThe task is choosing branch strategy, rebase vs merge, release tags, commit boundaries, or worktree lifecycle without changing canonical artifact ownership.
refactorThe task is behavior-preserving code restructuring inside an already canonical implementation path.
doc-updaterThe task is only routing a code change to its owning docs and verifying docs changed in the same commit.
taxonomy-designThe task is only designing categories, facets, controlled vocabularies, or classification assignment rules.
code-reviewThe task is reviewing a PR/diff holistically for bugs, security, performance, and tests.

Key Sources

  • AGENTS.md - repo ownership, document routing, and implementation ownership rules
  • docs/reference/implementation-ownership.md - canonical implementation registry and compatibility-shim contract
  • docs/reference/artifact-lifecycle-contract.md - lifecycle metadata and changelog discipline for non-skill artifacts
  • .claude/rules/delete-dont-archive.md - confirmed-dead code is deleted to git history, not archived in the tree
  • skill-graph/AGENTS.md - Skill Graph canonical-location rule, delete-to-git-history directive, and timestamped changelog requirement
  • skill-graph/SKILL_GRAPH.md - Skill Graph source vs generated marketplace distinction
  • docs/reference/documentation-standards.md - one canonical source per fact and generated/reference verification gates

What ships with it: 3 files

29.9 KB alongside SKILL.md

Gives 0 of the 12 instructions most pr commit review skills give in ~2.0k tokens

Counted across 888 of the 1,342 authors here whose files we hold, read 2026-08-07

  • Use conventional commits formatin 127 of 888, across 115 files
  • Keep subject line under 72 charactersin 62 of 888, across 48 files
  • Delete branches after mergein 51 of 888, across 38 files
  • Use imperative mood in subject linein 51 of 888, across 42 files
  • Use imperative mood in commit messagesin 44 of 888
  • Verify directory is ignored before creating worktreein 43 of 888, across 12 files
  • Generate a conventional commit messagein 43 of 888
  • Add unignored worktree directories to gitignorein 42 of 888, across 10 files
  • Make atomic commitsin 39 of 888, across 27 files
  • Run tests before committingin 36 of 888, across 25 files
  • Verify clean test baselinein 35 of 888, across 9 files
  • Split unrelated changes into separate commitsin 35 of 888, across 30 files

Said here and by no other author read

  • verify the nearest owning repository for each path
  • separate authored source from generated projections
  • update the existing owner instead of copying it
  • leave a registered thin shim for fixed runtime paths
  • remove confirmed-dead code to git history
  • update live references in the same change

Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once. Length counted with cl100k_base; the agent that loads this file may tokenize it differently.

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.