Skip to content

Evolve CLI

One evolve command for your whole project. The CLI itself only runs commands. The commands come from the Evolve packages you install, so each project has the commands that fit what it uses.

Install

pnpm add -D @evolve-framework/cli
pnpm evolve --help

--help lists the commands available in the current project. The CLI is @evolve-framework/cli v1.0.0.

Commands

CommandWhat it doesInstall
evolve addAdd a piece of Evolve wiring to this project (e2e, brand-contrast)@evolve-storefront/commands
evolve messagesGenerate the project's message files from its packages@evolve-storefront/commands
evolve cleanupDevelopment only. Delete what end-to-end runs left behind@evolve-framework/commercetools
evolve simulateDevelopment only. Write what an ERP, a warehouse and a merchant would@evolve-framework/commercetools
evolve ejectEject built-in blocks into your project so you own them@evolve-framework/contentful
evolve field-tabsPut every content type's fields on the Content, SEO and Settings tabs@evolve-framework/contentful
evolve tf-exportExport the built-in content blocks' Terraform to disk@evolve-framework/contentful
evolve cleanupDevelopment only. Delete what end-to-end runs left behind@evolve-framework/medusa
evolve ejectEject built-in blocks, collections or fields into your project so you own them@evolve-framework/payload
evolve ejectEject built-in blocks into your project so you own them@evolve-framework/storyblok
evolve tf-exportExport the built-in content blocks' Terraform to disk@evolve-framework/storyblok

The CLI has no commands of its own yet. Scaffolding a new project with evolve create is planned.

Global options

--helpList the commands, or with a command, its arguments: evolve eject --help.
--package <name>, -pOnly use this package's commands. It settles a command that two packages add, and runs a package's command without adding the package to your dependencies.

@evolve-storefront/commands

Available after pnpm add @evolve-storefront/commands. About this package

evolve add

Add a piece of Evolve wiring to this project (e2e, brand-contrast)

evolve add [what] [options]
ArgumentDescription
<what>What to add: e2e or brand-contrast
--stylesheetbrand-contrast: the brand stylesheet, when it is not found
--forceOverwrite files that already exist

evolve messages

Generate the project's message files from its packages

evolve messages <action> [options]
ArgumentDescription
<action>requiredWhat to do with the messages: "build"
--localeOnly this locale. Must be one of the configured locales.
--checkWrite nothing; exit non-zero if the files are not in sync

@evolve-framework/commercetools

Available after pnpm add @evolve-framework/commercetools. About this package

evolve cleanup

Development only. Delete what end-to-end runs left behind

evolve cleanup order deleteDevelopment only. Delete an order a test identity placed, with its payments, and put its stock back
evolve cleanup order delete --order <order> [options]
ArgumentDescription
--orderrequiredId of the order to delete
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup order delete-of-customerDevelopment only. Delete every order a test customer placed, with their payments, and put their stock back
evolve cleanup order delete-of-customer --customer <customer> [options]
ArgumentDescription
--customerrequiredId of the test customer whose orders to delete
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup payment deleteDevelopment only. Delete a payment a test identity made
evolve cleanup payment delete --payment <payment> [options]
ArgumentDescription
--paymentrequiredId of the payment to delete
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup cart deleteDevelopment only. Delete a test identity's cart, or an anonymous one
evolve cleanup cart delete --cart <cart> [options]
ArgumentDescription
--cartrequiredId of the cart to delete
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup quote-request deleteDevelopment only. Delete a test identity's quote request, or one whose customer is gone, with its staged quote and the quotes answering it
evolve cleanup quote-request delete --quote-request <quote-request> [options]
ArgumentDescription
--quote-requestrequiredId of the quote request to delete
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup associate removeDevelopment only. Remove a test identity from a business unit
evolve cleanup associate remove --business-unit <business-unit> --customer <customer> [options]
ArgumentDescription
--business-unitrequiredKey of the business unit to remove them from
--customerrequiredId of the test customer to remove
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup customer deleteDevelopment only. Delete a test customer
evolve cleanup customer delete --customer <customer> [options]
ArgumentDescription
--customerrequiredId of the test customer to delete
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup sweepDevelopment only. Find, and with --delete remove, the test data end-to-end runs left behind
evolve cleanup sweep [options]
ArgumentDescription
--deleteRemove what was found. Without it nothing is changed
--older-thanOnly what was created at least this many minutes ago, so a run still in flight keeps its data (default: 60)
--quotesAlso scan and remove quote requests. Needs a client with the quote scopes
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)

evolve simulate

Development only. Write what an ERP, a warehouse and a merchant would

evolve simulate invoice raiseDevelopment only. Raise an invoice, as a finance system would
evolve simulate invoice raise --amount <amount> [options]
ArgumentDescription
--amountrequiredWhat the invoice bills, in cents
--currencyCurrency the invoice bills inDefault EUR
--numberInvoice number (default: generated)
--invoice-dateWhen it was raised, YYYY-MM-DD (default: today)
--due-dateWhen payment is due, YYYY-MM-DD (default: 30 days out). A date in the past raises it overdue
--order-numberOrder numbers this invoice bills, comma separated. Omit for a standalone invoice
--business-unitKey of the company the invoice is billed to
--customerId of the person the invoice is billed to
--referenceCustomer reference
--urlLink to the invoice document
--payment-typeKey of the project's payment custom type (default: $CTP_PAYMENT_TYPE_KEY)
evolve simulate invoice payDevelopment only. Record money received against an invoice, in full or in part
evolve simulate invoice pay --invoice <invoice> [options]
ArgumentDescription
--invoicerequiredInvoice payment id
--amountHow much arrived, in cents. Omit to settle the outstanding balance
evolve simulate invoice creditDevelopment only. Raise a credit note against an invoice, as a finance system would
evolve simulate invoice credit --invoice <invoice> [options]
ArgumentDescription
--invoicerequiredId of the invoice being credited
--amountHow much to credit, in cents. Omit to credit the invoice in full
--numberCredit note number (default: generated)
--dateWhen it was raised, YYYY-MM-DD (default: today)
--referenceCustomer reference (default: the invoice's own)
--urlLink to the credit note document
--payment-typeKey of the project's payment custom type (default: $CTP_PAYMENT_TYPE_KEY)
evolve simulate invoice repair-statusDevelopment only. Write the status of every invoice that has none, from its transactions
evolve simulate invoice repair-status [options]
ArgumentDescription
--dry-runList what would be written without writing it
evolve simulate order confirmDevelopment only. Confirm an order, as a back office would
evolve simulate order confirm --order <order>
ArgumentDescription
--orderrequiredOrder id or order number
evolve simulate order shipment-stateDevelopment only. Report where an order's parcels are, as a warehouse would
evolve simulate order shipment-state --order <order> --state <state>
ArgumentDescription
--orderrequiredOrder id or order number
--staterequiredOne of Pending, Ready, Shipped, Delayed, Backorder, Canceled. Partial and Delivered come from simulate order deliver
evolve simulate order deliverDevelopment only. Deliver part or all of an order, moving the shipment and order state with it
evolve simulate order deliver --order <order> [options]
ArgumentDescription
--orderrequiredOrder id or order number
--itemsWhat to deliver, comma separated, as <line item id or SKU>[:<quantity>]. Defaults to everything still undelivered
--tracking-idCarrier's tracking reference for the parcel
--carrierCarrier delivering the parcel
evolve simulate quote sendDevelopment only. Answer a quote request with a quote, as a merchant would
evolve simulate quote send --quote-request <quote-request> [options]
ArgumentDescription
--quote-requestrequiredId of the quote request being answered
--valid-toWhen the offer lapses, YYYY-MM-DD (end of that day, UTC) or an ISO timestamp. A moment in the past sends an expired quote. Omit for no expiry
--pricesNegotiated prices, comma separated, as <line item id or SKU>:<cents>. Lines left out keep their price
--commentWhat the merchant tells the buyer about the offer
--numberThe seller's quote number, shown to the buyer. Omit for a quote without one
evolve simulate quote withdrawDevelopment only. Withdraw a quote before it is accepted, as a merchant would
evolve simulate quote withdraw --quote <quote>
ArgumentDescription
--quoterequiredId of the quote being withdrawn
evolve simulate quote declineDevelopment only. Decline a quote request outright, as a merchant would
evolve simulate quote decline --quote-request <quote-request>
ArgumentDescription
--quote-requestrequiredId of the quote request being declined
evolve simulate quote renegotiateDevelopment only. Answer a renegotiation request with a new quote, as a merchant would
evolve simulate quote renegotiate --quote <quote> [options]
ArgumentDescription
--quoterequiredId of the quote the buyer asked to renegotiate
--valid-toWhen the offer lapses, YYYY-MM-DD (end of that day, UTC) or an ISO timestamp. A moment in the past sends an expired quote. Omit for no expiry
--pricesNegotiated prices, comma separated, as <line item id or SKU>:<cents>. Lines left out keep their price
--commentWhat the merchant tells the buyer about the offer
--numberThe seller's quote number, shown to the buyer. Omit for a quote without one

@evolve-framework/contentful

Available after pnpm add @evolve-framework/contentful. About this package

evolve eject

Eject built-in blocks into your project so you own them

evolve eject [options]
ArgumentDescription
--allEject every block
--destDirectory for the ejected TypeScriptDefault src/blocks
--tf-destDirectory for the ejected TerraformDefault terraform/contentful

evolve field-tabs

Put every content type's fields on the Content, SEO and Settings tabs

evolve field-tabs

evolve tf-export

Export the built-in content blocks' Terraform to disk

evolve tf-export [out-dir]
ArgumentDescription
<out-dir>Directory to write the .tf files intoDefault terraform/contentful

@evolve-framework/medusa

Available after pnpm add @evolve-framework/medusa. About this package

evolve cleanup

Development only. Delete what end-to-end runs left behind

evolve cleanup order deleteDevelopment only. Cancel and archive a test order; Medusa cannot delete one
evolve cleanup order delete --order <order> [options]
ArgumentDescription
--orderrequiredId of the test order
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup order delete-of-customerDevelopment only. Cancel and archive every order a test customer placed
evolve cleanup order delete-of-customer --customer <customer> [options]
ArgumentDescription
--customerrequiredId of the test customer whose orders to retire
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup customer deleteDevelopment only. Delete a test customer
evolve cleanup customer delete --customer <customer> [options]
ArgumentDescription
--customerrequiredId of the test customer to delete
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)
evolve cleanup customer delete-by-emailDevelopment only. Delete every customer holding a test identity's address
evolve cleanup customer delete-by-email --email <email> [options]
ArgumentDescription
--emailrequiredThe test identity's address
--test-domainReserved domain every test identity's email is at (default: $TEST_IDENTITY_DOMAIN)
--test-prefixWhat every test identity's email starts with (default: $TEST_IDENTITY_PREFIX)

@evolve-framework/payload

Available after pnpm add @evolve-framework/payload. About this package

evolve eject

Eject built-in blocks, collections or fields into your project so you own them

evolve eject [options]
ArgumentDescription
--allEject every block, collection or field
--collectionsRead the names as collections rather than blocks
--destDirectory for the ejected blocksDefault src/blocks
--collections-destDirectory for the ejected collectionsDefault src/collections
--fieldsRead the names as fields rather than blocks
--fields-destDirectory for the ejected fieldsDefault src/fields

@evolve-framework/storyblok

Available after pnpm add @evolve-framework/storyblok. About this package

evolve eject

Eject built-in blocks into your project so you own them

evolve eject [options]
ArgumentDescription
--allEject every block
--destDirectory for the ejected TypeScriptDefault src/blocks
--tf-destDirectory for the ejected TerraformDefault terraform/storyblok

evolve tf-export

Export the built-in content blocks' Terraform to disk

evolve tf-export [out-dir]
ArgumentDescription
<out-dir>Directory to write the .tf files intoDefault terraform/storyblok