Adds `ocas tag <target> <tag>...` and `ocas untag <target> <tag>...`
top-level CLI commands operating on store.tag.* (TagStore). Targets
may be hashes or @scope/name variables (resolved via resolveHash).
The redundant `ocas var tag` subcommand is removed; `var tag` now
falls through to "Unknown var subcommand: tag".
Registers `@ocas/output/tag` and `@ocas/output/untag` schemas and
templates in bootstrap; removes `@ocas/output/var-tag`.
Closes#52
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Remove legacy `Store` type with `Promise<Hash>` `put`; rename `OcasStore` → `Store`
across @ocas/core, @ocas/fs, @ocas/cli (production + tests).
- Migrate `BootstrapCapableStore` to `CasStore`; `[BOOTSTRAP_STORE]` returns `Hash`
synchronously.
- Make `bootstrap()` and `putSchema()` synchronous; remove `await` at all call sites.
- Extract pure VarStore helpers into `packages/core/src/var-store-helpers.ts`
(`varKey`, `addNameIndex`, `removeNameIndex`, `extractSchema`, `checkTagLabelConflict`,
`pushHistory`, `cloneVarRecord`, `VarRecord`); both `MemoryVarStore` (-74 lines) and
`FsVarStore` (-63 lines) now delegate to them while keeping persistence separate.
Refs #47
All variable names must now follow @scope/name pattern:
- scope: @[a-zA-Z][a-zA-Z0-9]* (e.g. @myapp, @todo)
- name: one or more segments of [a-zA-Z0-9._-]+
- @ocas/* reserved for internal use
Examples: @myapp/config, @todo/schema, @ocas/schema (builtin)
Rejected: config (no scope), foo/bar (no @), @/foo (empty scope)
Updated validateName() in core, CLI error messages, and all tests.
594 tests pass.
Fixes#29
All commands (get, has, verify, refs, walk, list --type, var --schema)
now resolve variable names via resolveHash(). Added 7 e2e tests.
Also fixed isHash to use Crockford Base32 charset.
Fixes#19
- cas_ref → ocas_ref (schema format identifier)
- @schema → @ocas/schema, @string → @ocas/string, etc. (builtin type aliases)
- @output/* → @ocas/output/* (output schema aliases)
- Guard @ocas/ namespace in var set/delete CLI commands (reserved, not user-writable)
- Template commands use varStore directly, bypassing the guard
- Update all tests to use template set --inline instead of var set @ocas/
Breaking change: all builtin schema hashes will change due to payload changes.