Log inGet started
World

Builtin Library

Branchmain
Branchesmainpublish
Commit5e96992b1b

README.md

deps.worldSpec

A world's own dependency specs, /zero/source/dependencies.json ($schema: zero/world-deps/v1): the spec the world asks for each package it installs, and for any other package it constrains.

{
  "$schema": "zero/world-deps/v1",
  "dependencies": [
    { "asset_guid": "...", "name": "economyKit", "spec": "latest", "world_guid": "..." },
    { "asset_guid": "...", "name": "menusKit", "reason": "1.5.1 breaks the pause menu", "spec": "=1.5.0", "world_guid": "..." }
  ]
}

zm deps resolve adds each install of the world's own at latest and writes the file in one canonical form (keys sorted, two-space indent, entries sorted by name). A person edits an entry's spec to constrain a package (=1.5.0 pins exactly that release, >=1.4 sets a floor, ^1.4.10 a range; the grammar is deps.spec's) and states why in reason; a bare number is refused, since a world pins with an operator. An entry names its package by asset_guid (with world_guid), or by name.

  • encode(spec), decode(text) and check(text) write, read and hold the file to its schema. A commit refuses a file that does not read, naming it and the reason.
  • changes(before, after) names each spec that changed (menusKit latest -> =1.5.0), which zm diff prints for the file.
  • format is the entry modules.fileFormats knows the file by.