docs: add changesets for #52/#53 and update card docs for tag commands
This commit is contained in:
+12
-3
@@ -32,6 +32,7 @@ ocas verify <hash> # check integrity + schema validity
|
||||
ocas refs <hash> # list direct ocas_ref edges
|
||||
ocas walk <hash> # recursive DAG traversal
|
||||
ocas list --type <hash|name> # list nodes by type
|
||||
ocas list --tag <expr> # filter by tag
|
||||
ocas list-schema # list all schema hashes
|
||||
ocas list-meta # list meta-schema hashes
|
||||
ocas gc # garbage collection
|
||||
@@ -40,14 +41,22 @@ ocas gc # garbage collection
|
||||
### [[Variable]] Management
|
||||
|
||||
```bash
|
||||
ocas var set <name> <hash> [--tag key:value] [--tag label]
|
||||
ocas var set <name> <hash>
|
||||
ocas var get <name> --schema <hash>
|
||||
ocas var delete <name> [--schema <hash>]
|
||||
ocas var list [prefix] [--schema <hash>] [--tag ...]
|
||||
ocas var tag <name> --schema <hash> <operations...>
|
||||
ocas var list [prefix] [--schema <hash>]
|
||||
ocas var history <name> [--schema <hash>]
|
||||
```
|
||||
|
||||
### Tagging
|
||||
|
||||
```bash
|
||||
ocas tag <target> <tag>... # attach tags (key:value) or labels (bare)
|
||||
ocas untag <target> <tag>... # remove tags by key or label
|
||||
```
|
||||
|
||||
Tags apply to any target (variable or node). `ocas get` and `ocas var get` include tag info in output.
|
||||
|
||||
### [[Render System|Template & Render]]
|
||||
|
||||
```bash
|
||||
|
||||
+9
-5
@@ -41,18 +41,22 @@ The `@scope` prefix ensures variable names are visually distinct from 13-charact
|
||||
## Operations
|
||||
|
||||
```bash
|
||||
ocas var set <name> <hash> [--tag env:prod] [--tag pinned]
|
||||
ocas var set <name> <hash>
|
||||
ocas var get <name> --schema <hash>
|
||||
ocas var delete <name> [--schema <hash>]
|
||||
ocas var list [prefix] [--schema <hash>] [--tag env:prod]
|
||||
ocas var tag <name> --schema <hash> status:active pinned :archived
|
||||
ocas var list [prefix] [--schema <hash>]
|
||||
```
|
||||
|
||||
`var set` is an upsert — creates or updates. Name prefix filtering replaces the old scope concept: `var list myapp/` returns all variables under `myapp/`.
|
||||
`var set` is an upsert — creates or updates. Name prefix filtering replaces the old scope concept: `var list myapp/` returns all variables under `myapp/`. Tagging is now handled by the top-level `ocas tag` / `ocas untag` commands (see [[CLI]]).
|
||||
|
||||
## Tags and Labels
|
||||
|
||||
Tags and labels share a unified command (`var tag`):
|
||||
Tags and labels are managed via top-level `ocas tag` / `ocas untag` commands:
|
||||
|
||||
```bash
|
||||
ocas tag <target> env:prod pinned # set tag + label
|
||||
ocas untag <target> env pinned # remove by key/label
|
||||
```
|
||||
|
||||
- **Tags** are `key:value` pairs — same-key mutually exclusive (e.g. `env:prod` replaces `env:dev`)
|
||||
- **Labels** are bare strings (e.g. `pinned`, `important`)
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
---
|
||||
"@ocas/core": minor
|
||||
"@ocas/cli": minor
|
||||
---
|
||||
|
||||
Top-level tag/untag commands (#52)
|
||||
|
||||
- New `@ocas/output/tag` and `@ocas/output/untag` output schemas in core
|
||||
- New top-level `ocas tag <target> <tag>...` and `ocas untag <target> <tag>...` commands
|
||||
- Removed `ocas var tag` subcommand — tagging is now via top-level commands
|
||||
@@ -0,0 +1,9 @@
|
||||
---
|
||||
"@ocas/core": minor
|
||||
"@ocas/cli": minor
|
||||
---
|
||||
|
||||
get/var get now show tag info (#53)
|
||||
|
||||
- Extended `@ocas/output/get` and `@ocas/output/var-get` schemas to include tags
|
||||
- `ocas get` and `ocas var get` output now includes tag information
|
||||
Reference in New Issue
Block a user