Command reference
oko-cli transcripts tasks-relate
Records what one task is to another: duplicate-of, follows, blocked-by or part-of, by identity.
Invocation#
oko-cli transcripts tasks relate <task-id> <kind> <task-id> [--reason TEXT] [--by SESSION] [--db PATH] [--json]Inputs and options#
- The first <task-id> is the task the relation is read from, <kind> is one of duplicate-of, follows, blocked-by, part-of, and the second <task-id> is the other task; both are identities transcripts tasks prints.
- --reason says why in the operator’s words; --by names who records it (default operator); --db overrides the index; --json prints the recorded relation.
Output and state effect#
- Writes one row in task_relations and prints “recorded: <from> <kind> <to> (<reason>); the other way round it reads <to> <inverse> <from>” followed by the first task’s relations and what it waits on. From then on every listing, show and handover reads the relation: a duplicate takes its state from the original and waits while it is open; a task that follows or is blocked by an open task waits on it and is not handed over; a task with open parts says how many. Recording the relation does not edit any transcript or close anything the operator has not closed.
Refusals and safe exits#
- Refuses without three positionals and prints the usage. An unknown kind refuses with “<kind> is not a relation kind; the kinds are duplicate-of, follows, blocked-by, part-of”. The same task on both sides refuses with “task <id> cannot relate to itself”. An identity the index does not hold refuses with “no task <id> is in the transcript index; run `oko-cli transcripts tasks --session <id>` on the session that gave it so its ledger is written”. A pair already recorded refuses with “task <from> is already recorded as <kind> <to>”. A duplicate-of, follows or blocked-by chain that would return to its start refuses with “task <from> <kind> <to> would make a cycle: <from> -> … -> <from>”.