Catalog npm
Back to packageRELEASE DETAILS

0.10.0

npm

@0disoft/mensor-cli

CLI for checking Mensor project contracts.

clicontractsdeveloper-toolsmensorstatic-analysis
Published10 Sept 2026
Direct dependencies3
Transitive dependenciesNot calculated

README

Current package documentation

@0disoft/mensor-cli

Command-line interface for checking and compiling Mensor project contracts.

Install

pnpm add --save-dev @0disoft/mensor-cli

Node.js 22 or newer is required.

Check A Project

Run the default DiagnosticReport v1 output:

pnpm exec mensor check . --json

Select Check Output v2 when the consumer needs explicit inspection coverage:

pnpm exec mensor check . --json --report-version 2

Exit status 0 means every configured static contract check passed. It does not prove runtime application behavior. When a project omits RouteIndex, application route declarations are not inspected.

Mensor does not execute project source or configuration while checking it.

Emit SARIF 2.1.0 for code-scanning consumers:

pnpm exec mensor check . --sarif

SARIF is available only for completed checks and cannot be combined with --json or --report-version.

Compile A Runtime Manifest

Compile only after all configured checks pass and atomically replace the root-relative output file:

pnpm exec mensor compile . --out .mensor/manifest.json

The default output is .mensor/manifest.json. Diagnostic, configuration, and write failures do not replace an existing manifest. Add --json to emit the same canonical manifest bytes to stdout after the file is written.

Produce A Hono RouteIndex

Generate a canonical RouteIndex from explicitly selected Hono source files and receiver identifiers:

pnpm exec mensor index-hono-routes . --source src/routes.ts --receiver app

Repeat --source and --receiver when needed. The default output is mensor.route-index.json; --out selects another root-relative path and --json emits the same canonical bytes after the atomic write. Mensor parses source without importing or executing it. Only direct or chained static receiver.get() and receiver.post() calls are supported. Dynamic paths, mounted routers, on, all, and optional chains fail closed rather than producing an incomplete index.

Produce A TypeScript FormIndex

Generate a canonical FormIndex from explicitly selected TypeScript or JavaScript files and tagged-template identifiers:

pnpm exec mensor index-ts-forms . --source src/views.ts --tag html

Repeat --source and --tag when needed. The default output is mensor.form-index.json; --out selects another root-relative path and --json emits the same canonical bytes after the atomic write. Mensor parses without importing or executing source. Only exact identifier tags with no-substitution templates yield static form facts. Interpolation is retained as incomplete evidence, and a source with no selected template fails closed.

Produce A Hono JSX FormIndex

pnpm exec mensor index-hono-jsx-forms . --source app/routes/index.tsx --jsx-config tsconfig.json --build-config vite.config.ts --renderer app/routes/_renderer.tsx

This explicit producer supports a bounded static HonoX configuration and transparent Hono renderer. It never executes source or configuration. The artifact includes configuration digests. With sourceRoot: "app", declare formIndexEvidence: ["tsconfig.json", "vite.config.ts"] alongside formIndex in the Mensor project contract. These explicit files are freshness evidence, not additional application sources. Custom transforms and nested renderers fail closed. See the supported subset.

Documentation

Mensor is licensed under Apache-2.0.

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 3

Native requirements
3 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
@typescript/typescript6
Environment
{
  "local_name": "@typescript/typescript6",
  "alias": false,
  "peer_metadata": null
}
6.0.2runtime
@0disoft/mensor-compiler
Environment
{
  "local_name": "@0disoft/mensor-compiler",
  "alias": false,
  "peer_metadata": null
}
0.10.0runtime
@0disoft/mensor-contract
Environment
{
  "local_name": "@0disoft/mensor-contract",
  "alias": false,
  "peer_metadata": null
}
0.10.0runtime

Distribution files

1 collected
Distribution 1

Source distribution

Source file
Checksums from source
{
  "shasum": "17b67010e5ae0912ceb5b51356bf0de47e39aa7b",
  "tarball": "https://registry.npmjs.org/@0disoft/mensor-cli/-/mensor-cli-0.10.0.tgz",
  "fileCount": 47,
  "integrity": "sha512-5wrgzBGjnJH3JAdeLZQ867CmvCNZJl+XeO8+l9A6p4bhsYSVwBwzD6MpOehENz+ULdOgztRgzgHQ7khWgJFz4Q==",
  "signatures": [
    {
      "sig": "MEUCIQCGb6yMcP/x5UoOFXdfH/9Qyv/5K2G+7XbKPdy/inBC7QIgBxpPYOAj0f0YPaR6+6FdPi5auAVlpqa48UX2pBf11xM=",
      "keyid": "SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"
    }
  ],
  "attestations": {
    "url": "https://registry.npmjs.org/-/npm/v1/attestations/@0disoft%2fmensor-cli@0.10.0",
    "provenance": {
      "predicateType": "https://slsa.dev/provenance/v1"
    }
  },
  "unpackedSize": 176189
}

Repository

PENDING
0disoft/mensor

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 22:08 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:3d43d6a45cdfc703c122579d32d6dedbbd9ea981dfcb6004dc1bdd995706845e

Other collected versions

0.10.212 Sept0.10.111 Sept0.9.01 Sept0.2.19 Aug0.2.022 Jul0.1.020 JulView all collected versions →