IF Commons GitHub

The shared kit of the dialects that drive a package manager for Archon (commons archon 0004-archon-dialects) and Toolchain (commons toolchain 0003-toolchain-logical): it is a library in the layers of Kanon, and the dialects of Homebrew, apt, WinGet and mise are packages of their own that hold only the data of a manager. Kanon lets a dialect reach its host and no other member of the family, so the code the dialects share lives in a library that is no member.

0001Active

0001-package-managers-layers · owner if · domain commons

Requirements

FR-001checkpassing

The library MUST be Kanon: its manifest library.ts MUST declare the table of its units in the field kanon, with src/governance/, src/logical/ and src/physical/, and the shared checker of @intellectual-frontiers/kanon MUST find no import that the table does not allow.

Enforced (check): .github: cd commons/package-managers && bun run verify — suite/layers.test.ts

Proved by: package-managers/suite/layers.test.ts

Written in: package-managers/about.ts, package-managers/library.ts, package-managers/src/governance/mod.ts, package-managers/src/logical/mod.ts, package-managers/src/physical/mod.ts

Tests: passed: suite/layers.test.ts the shared checker finds nothing in the real tree, and a file in no unit is layers/unclass

FR-002checkpassing

Governance MUST import nothing but @intellectual-frontiers/core; Logical MUST import Governance, core, and the governance and dialect port of Archon and the governance and logical of Toolchain; Physical MUST import Governance, Logical, core, the process module of @intellectual-frontiers/system, and Archon and Toolchain by their exports; no unit MUST import a dialect package.

Enforced (check): .github: cd commons/package-managers && bun run verify — suite/layers.test.ts

Proved by: package-managers/suite/layers.test.ts

Tests: passed: suite/layers.test.ts below may not import above, a unit reaches another through exports, and each unit imports

FR-003checkpassing

The package MUST export ., ./governance, ./logical and ./physical.

Enforced (check): .github: cd commons/package-managers && bun run verify — suite/layers.test.ts

Proved by: package-managers/suite/layers.test.ts

Written in: package-managers/src/mod.ts

Tests: passed: suite/layers.test.ts the package exports the library and its layers

FR-004checkpassing

bun run verify in the folder of the library MUST run the TypeScript 7 compiler, the checks of the specification kit, the check of the level L1, the layers check of Kanon, the trace check, the tests under Bun and the check of the package, and MUST fail on any finding that is not held by a baseline that only shrinks.

Enforced (check): .github: cd commons/package-managers && bun run verify — suite/layers.test.ts

Proved by: package-managers/suite/layers.test.ts

Tests: passed: suite/layers.test.ts verify runs the compiler, the specification checks, the layers check, the trace check, the

FR-005checkpassing

The library MUST be released as package-managers-v<version> (commons 0026-works-versioning).

Enforced (check): .github: cd commons/package-managers && bun run verify — suite/layers.test.ts

Proved by: package-managers/suite/layers.test.ts

Written in: package-managers/tools/check.ts, package-managers/tools/pack.ts

Tests: passed: suite/layers.test.ts the release record agrees with the manifest and the package

FR-006checkpassing

Governance and Logical MUST do no input or output: they MUST NOT read a file, reach the network or run a program; only the runner of Physical runs one.

Enforced (check): .github: cd commons/package-managers && bun run verify — suite/layers.test.ts

Proved by: package-managers/suite/layers.test.ts

Tests: passed: suite/layers.test.ts below may not import above, a unit reaches another through exports, and each unit imports ; passed: suite/layers.test.ts governance and logical read no file, reach no network and run no program

Acceptance scenarios

  1. Given the real tree of the library, When the layers check runs, Then every file is in a unit and no import is outside its row, per FR-001 and FR-002.
  2. Given a file of Logical that imports the process module, When the layers check runs, Then it is a finding, per FR-002 and FR-006.

Out of scope

  • The dialects of the managers: packages of their own.
  • Reading the ontology: its reader of commands; the adapter of Physical only calls it.

Edge cases

  • The module at the top of src/ that re-exports the layers is in a unit of its own and reaches them by relative path, per FR-001.

Assumptions

  • The layers check of Kanon is the one place the import rules are held.

Open questions

  • None.

Key entities

  • Kit - this library: the code the dialects of the managers share.

Success criteria

SC-001success criterion

A manager dialect is data and a few lines, and holds no logic of its own.

Review & acceptance checklist

  • [x] Every requirement is testable (MUST / MUST NOT), not aspirational
  • [x] No company fact is asserted here
  • [x] Every open item is marked, not silently decided

Titles, headings, exports, tables, columns and requirements. Esc closes.