UiPath Documentation
uipath-cli
latest
false

UiPath CLI user guide

上次更新日期 2026年5月7日

uip flow init

uip flow init scaffolds a new Flow project directory with a minimal manifest and a starter .flow file containing a single manual-trigger node.

Synopsis

uip flow init <name> [--force]
uip flow init <name> [--force]

Honors global options. Exit codes follow the standard contract.

参数

  • <name> (required) — project folder name. Validated against VALID_PROJECT_NAME_REGEX: letters, numbers, underscores (_), and hyphens (-) only.

选项

  • --force — initialize even if the target directory exists and is non-empty. Existing files are not cleared — files are written alongside; this is useful for reinitializing inside a pre-created folder.

行为

The command creates <name>/ in the current working directory and writes two files:

  • project.uiproj{ "Name": "<name>", "ProjectType": "Flow" }
  • <name>.flow — seed Flow JSON containing:
    • One core.trigger.manual start node wired to a generated entryPointId
    • The matching node definition in definitions[]
    • Empty edges, bindings, variables
    • Canvas layout.nodes.start position

If <name> already exists and is non-empty and --force is not set, the command fails with an error prompting the user to pass --force.

示例

# Create a new project in ./invoice-flow
uip flow init invoice-flow

# Reinitialize into an existing non-empty folder (e.g. a Git repo)
uip flow init invoice-flow --force
# Create a new project in ./invoice-flow
uip flow init invoice-flow

# Reinitialize into an existing non-empty folder (e.g. a Git repo)
uip flow init invoice-flow --force

Data shape (--output json)

{
  "Code": "FlowInit",
  "Data": {
    "Status": "Created successfully",
    "Path": "/workspace/invoice-flow"
  }
}
{
  "Code": "FlowInit",
  "Data": {
    "Status": "Created successfully",
    "Path": "/workspace/invoice-flow"
  }
}

On failure, Code is absent and the response carries Result: "Failure", Message, and Instructions.

另请参阅

此页面有帮助吗?

连接

需要帮助? 支持

想要了解详细内容? UiPath Academy

有问题? UiPath 论坛

保持更新