redirects
engine-dmo redirects: The redirect rules table: list, import a CSV with a dry run, roll an import back. Every subcommand, argument and flag.
The redirect rules table: list, import a CSV with a dry run, roll an import back.
| Command | What it does |
|---|---|
engine-dmo redirects import | Import exact redirect rules from a CSV (source, target, status, locale, note); --dry-run writes nothing |
engine-dmo redirects list | A site’s redirect rules from the table, newest first, of one origin with --origin |
engine-dmo redirects rollback | Disable every rule an import batch wrote; audited |
engine-dmo redirects import
Reads a CSV with a header row naming source and target, and optionally status, locale and note (other columns are ignored). A target is a path on the site, an absolute URL, document:<uuid> (the rule follows the document if its address changes), or empty with status 410. Each row is checked: the source and status, the locale, a duplicate in the file or the table, the target (a document that exists, a path the site answers), and loops and chains through every rule the site has. Any error refuses the whole import unless --skip-invalid; the import is one transaction, and engine-dmo redirects rollback --batch disables it.
engine-dmo redirects import [flags] | Flag | Type | Default | Meaning |
|---|---|---|---|
--dry-run | bool | check every row and write nothing | |
--file | string | the CSV file | |
--site | string | site key (default: the default site) | |
--skip-invalid | bool | import the rows without errors when some have them |
--json prints the command’s own JSON document. Runs in a project.
engine-dmo redirects list
A site’s redirect rules from the table, newest first, of one origin with --origin.
engine-dmo redirects list [flags] | Flag | Type | Default | Meaning |
|---|---|---|---|
--origin | string | only this origin: managed, imported, auto_slug, auto_trash and the rest | |
--site | string | site key (default: the default site) |
--json prints the command’s own JSON document. Runs in a project.
engine-dmo redirects rollback
Disable every rule an import batch wrote; audited.
engine-dmo redirects rollback [flags] | Flag | Type | Default | Meaning |
|---|---|---|---|
--batch | string | the batch id the import printed | |
--site | string | site key (default: the default site) |
--json prints the text output in the JSON envelope. Runs in a project.