Skip to content

Configuration manifests ​

FieldValue
Slugconfig-manifests
Statusimplemented
Last review2026-08-10

Summary ​

Defines the three skli configuration JSON files, their lazy creation, and cross-platform paths (Windows / Unix).

User flows ​

Flow-01 — Lazy creation ​

Persona: skli CLI.
Preconditions: file or parent directory missing.

StepActionExpected resultError
1First write to a Manifest or ProjectIndexParent directories created; initial JSON file writtenEACCES / disk full

Data model ​

Common Manifest fields — skli.json ​

FieldTypeRequiredConstraintsNotes
versionnumberyesinteger ≥ 1File schema version
skillsobjectyesmap id → entryskill Packages
rulesobjectyesmap id → entryrule Packages
agentsobjectyesmap id → entryagent Packages

Package entry (map value) ​

FieldTypeRequiredConstraintsNotes
source"local" | "repos"yesPackageSourceOriginOrigin kind
reposstringif source=reposowner/repoOmitted when local
pathstringyesPOSIX relative pathPath in repo (repos) or relative to project (local)
versioningVersioningModeyesglossary enumPer-package; install default tag; add uses none
versionstringif source=reposnon-emptyCurrently installed version (a git tag when versioning=tag); omitted when local
ideIdeIdif source=localglossary enumSingle target IDE; omitted when repos
idesIdeId[]if source=reposnon-empty, uniqueIDEs installed into; omitted when local
includeReferencesbooleanskill installsdefault trueWritten by skli install … skill; whether references/ was copied

Example — repos skill with references excluded:

json
{
  "source": "repos",
  "repos": "owner/repo",
  "path": "skills/my-skill",
  "versioning": "tag",
  "version": "v1.2.0",
  "ides": ["cursor", "claude"],
  "includeReferences": false
}

Example — local rule:

json
{
  "source": "local",
  "path": ".cursor/rules/my-rule.mdc",
  "versioning": "none",
  "ide": "cursor"
}

ProjectManifest — project metadata ​

In addition to common fields, the ProjectManifest ({project}/.skli/skli.json) carries:

FieldTypeRequiredConstraintsNotes
$schemastringnoURIIDE tooling; written by init
namestringyes (after init)non-empty recommendedProject name
descriptionstringyes (after init)May be ""
versioningVersioningModeyes (after init)glossary enumDefault tag at init
tagsstring[]yes (after init)trimmed non-empty stringsMay be []
linksobjectnomap owner/repo → LinkEntryProject-only; absent ⇒ no links

Link entry (links map value) ​

FieldTypeRequiredConstraintsNotes
reposstringyesowner/repoSame as map key
versioningVersioningModeyesglossary enumResolve policy for the linked repo
versionstringyesnon-emptyPinned version of the remote ProjectManifest / packages
idesIdeId[]yesnon-empty, uniqueIDEs the linked packages were copied into
skillsLinkResourceSelectionyesSelection for skills
rulesLinkResourceSelectionyesSelection for rules
agentsLinkResourceSelectionyesSelection for agents

LinkResourceSelection ​

FieldTypeRequiredConstraintsNotes
includeAllbooleanyesWhen true, every package of that kind in the remote manifest (at link / update time)
includesstring[]yespackage idsWhen includeAll is false, only these ids; may be [] when includeAll is true

Linked packages are not duplicated into local skills / rules / agents maps. Paths are resolved by reading the remote ProjectManifest at version.

Example — link with mixed selection:

json
"links": {
  "zortracks/skli": {
    "repos": "zortracks/skli",
    "versioning": "tag",
    "version": "v0.1.0",
    "ides": ["cursor"],
    "skills": { "includeAll": false, "includes": ["arcade-bootstrap"] },
    "rules": { "includeAll": true, "includes": [] },
    "agents": { "includeAll": false, "includes": [] }
  }
}

Tolerant read: manifests without metadata, $schema, or links remain readable (package maps; missing links ⇒ treat as {}).

Published JSON Schema (Draft 2020-12): schemas/skli.project.schema.json. Canonical $schema URL written by init:

https://raw.githubusercontent.com/zortracks/skli/main/schemas/skli.project.schema.json

Initial value after skli init (example):

json
{
  "$schema": "https://raw.githubusercontent.com/zortracks/skli/main/schemas/skli.project.schema.json",
  "version": 1,
  "name": "my-repo",
  "description": "",
  "versioning": "tag",
  "tags": [],
  "skills": {},
  "rules": {},
  "agents": {}
}

GlobalManifest ​

Same common fields (version, skills, rules, agents). No project metadata (name, description, versioning, tags).

Initial value (empty global manifest):

json
{
  "version": 1,
  "skills": {},
  "rules": {},
  "agents": {}
}

ProjectIndex — projects.json ​

FieldTypeRequiredConstraintsNotes
versionnumberyesinteger ≥ 1Schema version
projectsstring[]yesunique absolute pathsReferenced project paths

Initial value:

json
{
  "version": 1,
  "projects": []
}

CLI ​

No dedicated command; used by add, install, init, etc.

Business rules ​

IdRule
BR-config-001ProjectManifest = {project}/.skli/skli.json.
BR-config-002GlobalManifest = ~/.skli/skli.json.
BR-config-003ProjectIndex = ~/.skli/projects.json.
BR-config-004~ = user home (os.homedir()).
BR-config-005Read/write helpers: create missing directories; if file missing on read, initial value is allowed. Creation of the ProjectManifest for a project is owned by init (not add).
BR-config-006Paths in projects are stored absolute and normalized.
BR-config-007Adding a path already present in projects: no-op (no duplicate).
BR-config-008Metadata name, description, versioning, tags are reserved for the ProjectManifest.
BR-config-009ProjectManifest JSON Schema lives at schemas/skli.project.schema.json; $schema (when present) points at the raw GitHub URL on main.
BR-config-010Package entry with source=repos and versioning=tag: version is a git tag name (never a branch).
BR-config-011source=local ⇒ required ide (single IdeId); source=repos ⇒ required ides (IdeId[], min 1).
BR-config-012links is ProjectManifest-only; GlobalManifest must not carry links.
BR-config-013Link key and repos are owner/repo; each kind has includeAll + includes.

User scenarios ​

After skli init, the ProjectManifest exists with metadata; skli add can reference Packages in it. install may create / update manifests and ProjectIndex per its pipeline.

Dependencies ​

Out of scope ​

  • Schema version migration (tolerant read of older ProjectManifests without metadata).
  • Concurrent file locking.
  • GlobalManifest / ProjectIndex published JSON Schemas.
  • Runtime validation of manifests against the JSON Schema.

Acceptance criteria ​

  • [x] Lazy read/write helpers for all 3 files.
  • [x] Paths resolved correctly on Windows and Unix.
  • [x] Empty manifest / post-init ProjectManifest match the model above.
  • [x] Published ProjectManifest JSON Schema at schemas/skli.project.schema.json.
  • [x] Post-init ProjectManifest includes $schema pointing at the canonical raw GitHub URL.
  • [x] ProjectManifest JSON Schema documents optional links / LinkEntry.

Terminology ​

See domain-glossary.

Implementation notes ​

Module src/lib/paths.ts + src/lib/manifests.ts. Schema file: schemas/skli.project.schema.json.

Released under the MIT License.