Files
medusa-store/www/apps/resources/app/medusa-cli/commands/exec/page.mdx
Shahed Nasser 0a37675f0e docs: add routing page (#9550)
- Add a new homepage to `book` project for the routing page
- Move all main doc pages to be under `/v2/learn` (and added redirects + fixed links across docs)
- Other: add admin components to resources dropdown + fixes to search on mobile.

Closes DX-955

Preview: https://docs-v2-git-docs-router-page-medusajs.vercel.app/v2
2024-10-18 08:24:34 +00:00

66 lines
1.2 KiB
Plaintext

---
sidebar_label: "exec"
sidebar_position: 6
---
import { Table } from "docs-ui"
export const metadata = {
title: `exec Command - Medusa CLI Reference`,
}
# {metadata.title}
Run a custom CLI script. Learn more about it in [this guide](!docs!/learn/advanced-development/custom-cli-scripts).
```bash
npx medusa exec [file] [args...]
```
## Arguments
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>Argument</Table.HeaderCell>
<Table.HeaderCell>Description</Table.HeaderCell>
<Table.HeaderCell>Required</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
`file`
</Table.Cell>
<Table.Cell>
The path to the TypeScript or JavaScript file holding the function to execute.
</Table.Cell>
<Table.Cell>
Yes
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
`args`
</Table.Cell>
<Table.Cell>
A list of arguments to pass to the function. These arguments are passed in the `args` property of the function's object parameter.
</Table.Cell>
<Table.Cell>
No
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>