martha schema prints the declaration's schema (#317 L1) #318
Loading…
Reference in a new issue
No description provided.
Delete branch "pluto/317-schema"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
martha schemaprints the declaration's JSON Schema (2020-12,x-martha-schema: 1), built from the constants the reader already uses, with the eight editor tabs inx-martha-tabs. The output is committed atschema/martha.schema.json, and an ordinary test insidenpm testasserts the committed file is exactly what the command prints.src/declare_crew/the_declarations_schema.ts: the tabs, fields, hints, defaults and enums (HOSTS_IT_KNOWS,TERMINALS, the hosts' model names), every word imported from the reader's own constant.src/run_the_martha_command/the_schema_the_command_prints.ts: the command's text, one call shared by the command and the test.run_the_martha_command.ts:schemaas an act of its own, in USAGE and HELP, printed line by line soshownSafelyescapes nothing inside it.src/run_the_martha_command/the_schema_is_the_one_committed.node-test.ts: the equality, the dialect and major, the tabs and fields, every house rule/act/mesh value, and the enums read back from their constants.Refs #317