@eventcatalog/cli 0.3.1 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli/index.js +579 -4
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/index.mjs +579 -4
- package/dist/cli/index.mjs.map +1 -1
- package/dist/cli/logo.png +0 -0
- package/dist/cli-docs.js +31 -0
- package/dist/cli-docs.js.map +1 -1
- package/dist/cli-docs.mjs +31 -0
- package/dist/cli-docs.mjs.map +1 -1
- package/package.json +4 -1
package/dist/cli-docs.mjs
CHANGED
|
@@ -1624,6 +1624,37 @@ var cliFunctions = [
|
|
|
1624
1624
|
command: "npx @eventcatalog/cli export --resource services --hydrate --playground"
|
|
1625
1625
|
}
|
|
1626
1626
|
]
|
|
1627
|
+
},
|
|
1628
|
+
// ================================
|
|
1629
|
+
// Import
|
|
1630
|
+
// ================================
|
|
1631
|
+
{
|
|
1632
|
+
name: "import",
|
|
1633
|
+
description: "Import EventCatalog DSL (.ec) files into catalog markdown files. Existing resources with the same version are overridden. Importing a newer version automatically moves the old version into the versioned/ folder.",
|
|
1634
|
+
category: "Import",
|
|
1635
|
+
args: [
|
|
1636
|
+
{ name: "files", type: "string", required: false, description: "One or more .ec file paths to import" },
|
|
1637
|
+
{ name: "stdin", type: "boolean", required: false, description: "Read DSL from stdin" },
|
|
1638
|
+
{ name: "dry-run", type: "boolean", required: false, description: "Preview resources without writing" }
|
|
1639
|
+
],
|
|
1640
|
+
examples: [
|
|
1641
|
+
{
|
|
1642
|
+
description: "Import a single .ec file",
|
|
1643
|
+
command: "npx @eventcatalog/cli import catalog.ec"
|
|
1644
|
+
},
|
|
1645
|
+
{
|
|
1646
|
+
description: "Import multiple .ec files",
|
|
1647
|
+
command: "npx @eventcatalog/cli import services.ec events.ec"
|
|
1648
|
+
},
|
|
1649
|
+
{
|
|
1650
|
+
description: "Import from stdin (pipe from export)",
|
|
1651
|
+
command: "npx @eventcatalog/cli export --all --stdout | npx @eventcatalog/cli import --stdin -d ./new-catalog"
|
|
1652
|
+
},
|
|
1653
|
+
{
|
|
1654
|
+
description: "Preview what would be written or merged",
|
|
1655
|
+
command: "npx @eventcatalog/cli import catalog.ec --dry-run"
|
|
1656
|
+
}
|
|
1657
|
+
]
|
|
1627
1658
|
}
|
|
1628
1659
|
];
|
|
1629
1660
|
function getCategories() {
|