Skip to content

[CAS-002] CLI content set|show|meta|delete commands #273

@flyingrobots

Description

@flyingrobots

CAS-002: CLI content commands

Parent: #271 (M13 VESSEL)
Depends: #272 (CAS-001)

Deliverable

Four new CLI commands in src/cli/commands.js:

  • git mind content set <node> --from <file> — read file, detect MIME, write to CAS, set properties
  • git mind content show <node> [--raw] — read and display content (--raw for piping, no metadata header)
  • git mind content meta <node> [--json] — show content metadata
  • git mind content delete <node> — remove content attachment

Design

  • MIME detection: use file extension mapping (.mdtext/markdown, .txttext/plain, etc.)
  • content set accepts --mime override for explicit MIME type
  • content show without --raw prints a metadata header then content body
  • content delete confirms node exists and has content before removing
  • --json support on all commands following established pattern
  • Chalk formatting for human-readable output

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions