Source importers: lstat before open so FIFOs no longer hang the directory walk; replace the quadratic Rust macro regex with a linear scan. Three-way sync: report page add/add and delete-vs-modify as conflicts instead of silently overwriting or resurrecting; canonical comparison so key order is not a change; the sync action withholds output and fails on conflicts unless --force. Story publishing escapes <, >, & and U+2028/9 inside the embedded JSON. Views: drop parentId of unselected containers, re-layout instead of manual geometry, validate before serialising; flatten() merges identical nodes repeated across pages so C4 output works with every analysis action. Dark theme edge labels get a background; tube-map corridors sit above the stations; C4 containers keep the swimlane style and orphan relationships land on the matching page; router keeps container header bands as obstacles; sequence self-messages loop on one side. Docs: SKILL.md lists all 23 CLI actions and how each capability family is invoked, task wrappers for query/test/what-if/doctor, capability tables and --page scope corrected, maintenance snippet uses the real synchronous action signature, duplicated rule bullets moved to the rule references, coverage matrix wording made verifiable. Co-Authored-By: Claude Code <noreply@anthropic.com>
132 lines
3.4 KiB
YAML
132 lines
3.4 KiB
YAML
# https://taskfile.dev
|
|
|
|
version: "3"
|
|
|
|
includes:
|
|
base: ./.scripts/base/Taskfile.yml
|
|
cli: ./.scripts/cli/Taskfile.yml
|
|
|
|
tasks:
|
|
default:
|
|
cmds:
|
|
- task --list-all
|
|
silent: true
|
|
|
|
build:
|
|
desc: Compile TypeScript source to dist/
|
|
cmds:
|
|
- task: cli:build
|
|
silent: true
|
|
|
|
run:
|
|
desc: |
|
|
Run any drawio-tools action against a .drawio file or Diagram IR model (see `task cli:run` for the action list).
|
|
Usage: task run -- --file="/path/to/diagram.drawio" --action=<action> [--page <index>] [--output <path>]
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "{{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
generate:
|
|
desc: |
|
|
Build a native .drawio file from a YAML Diagram IR.
|
|
Usage: task generate -- --file="spec.yaml" --output="diagram.drawio"
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=build {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
import:
|
|
desc: Loss-aware Draw.io import to Diagram IR v2; requires --file and --output.
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=import {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
edit:
|
|
desc: Apply an atomic stable-ID edit batch; requires --file and --spec.
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=edit {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
views:
|
|
desc: Project linked audience views to a multi-page Draw.io file.
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=views {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
query:
|
|
desc: |
|
|
Filter a Diagram IR v2 model by kind/property, or find a directed path.
|
|
Usage: task query -- --file="model.yaml" --kind=service | --property=k=v | --from=<id> --to=<id>
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=query {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
test:
|
|
desc: |
|
|
Run built-in architecture policy rules against a Diagram IR v2 model.
|
|
Usage: task test -- --file="model.yaml" [--spec="policy-rules.yaml"] [--strict]
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=test {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
what-if:
|
|
desc: |
|
|
Calculate outgoing failure impact from one node; requires --file and --fail.
|
|
Usage: task what-if -- --file="model.yaml" --fail=<node-id>
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=what-if {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
sync:
|
|
desc: |
|
|
Three-way stable-ID synchronization; requires --base, --file, and --spec.
|
|
Usage: task sync -- --base="before.yaml" --file="edited.yaml" --spec="after.yaml" --output="synced.drawio" [--prune] [--dry-run]
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=sync {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
doctor:
|
|
desc: |
|
|
Report optional local backend availability without launching anything; no --file needed.
|
|
Usage: task doctor
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=doctor {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
story:
|
|
desc: Publish a self-contained accessible offline architecture story.
|
|
cmds:
|
|
- task: cli:run
|
|
vars:
|
|
CLI_ARGS: "--action=story {{ .CLI_ARGS }}"
|
|
silent: true
|
|
|
|
validate:
|
|
desc: |
|
|
Validate a .drawio file (XML well-formedness + required structure).
|
|
Usage: task validate -- --file="/path/to/diagram.drawio"
|
|
cmds:
|
|
- task: cli:validate
|
|
vars:
|
|
CLI_ARGS: "{{ .CLI_ARGS }}"
|
|
silent: true
|