Lock File

cmx records installed state in JSON lock files.

Locations

ScopePathPurpose
Global~/.config/context-mixer/cmx-lock.jsonPersonal install manifest
Local.context-mixer/cmx-lock.jsonProject-level, can be committed for team sharing

Format

{
  "version": 1,
  "packages": {
    "python-craftsperson": {
      "type": "agent",
      "version": "1.3.1",
      "installed_at": "2026-03-20T10:30:00Z",
      "source": {
        "repo": "guidelines",
        "path": "agents/python-craftsperson.md"
      },
      "source_checksum": "sha256:abc123...",
      "installed_checksum": "sha256:abc123..."
    }
  }
}

Fields

FieldDescription
typeagent or skill
versionFrom frontmatter at install time (null if absent)
installed_atISO 8601 timestamp
source.repoName of the registered source
source.pathRelative path within the source
source_checksumSHA-256 of the artifact in the source at install time
installed_checksumSHA-256 of what was written to disk

How checksums are used

  • source_checksum vs current source — detects upstream changes
  • installed_checksum vs current file — detects local edits
  • Both match at install time, then drift independently