For the complete documentation index, see llms.txt. This page is also available as Markdown.
Cortex XSOAR 6.xCortex XSOAR 8 (SaaS)Cortex XSOAR 8.x (On-premCortex XSIAM

split

Split Cortex content files into the standard pack directory structure.

The split command splits downloaded scripts, integrations, and generic module files into multiple files. Integrations and scripts are split into the package format. Generic modules dashboards are split into separate files and the modules are modified to meet the content repository standard.

Files are stored in the content repository in a directory format, which enables performing extensive code validations and maintaining a more stable codebase.

Arguments
Argument
Description

-i, --input

The YAML/JSON file to extract from.

-o, --output

The output directory to write the extracted code/description/image/JSON to.

--no-demisto-mock

Does not add an import for demistomock (only for YAML files).

--no-common-server

Does not add an import for CommonServerPython or CommonServerPowerShell (only for YAML files).

--no-auto-create-dir

Does not automatically create the directory if the target directory ends with *Integrations/*Scripts/*GenericModules/*Dashboards. The automatically created directory is named according to the integration/script name.

--new-module-file

Creates a new module file instead of editing the existing file. Only for JSON files.

Examples
  • demisto-sdk split -i Integrations/integration-MyInt.yml -o Integrations/MyInt

    Splits the YAML file to a directory with the integration components (for example, code, image, description, and Pipfile).

  • demisto-sdk split -i Scripts/script-MyInt.yml -o Scripts/MyInt

    Splits the YAML file to a directory with the script components (for example, code, description, and Pipfile).

  • demisto-sdk split -i Integrations/integration-powershell_ssh_remote.yml -o Packs/PowerShellRemoting/Integrations/

    Splits a PowerShell integration. Output specifies just the integration's directory, so the target directory will be auto-created.

  • demisto-sdk split -i Packs/ThreatIntel/GenericModules/genericmodule-ThreatIntel.json

    Extracts the dashboards in the Generic Module under Packs/ThreatIntel/GenericModules/genericmodule-ThreatIntel.json. If this command is run in the content repository, the dashboards are extracted to the relevant directory in the pack: Packs/ThreatIntel/Dashboards. Otherwise, the dashboards are created in the current working directory. The Generic Module is also edited to fit the content standard.

  • demisto-sdk split -i Packs/ThreatIntel/GenericModules/genericmodule-ThreatIntel.json -o Packs/ThreatIntel --new-module-file

    Extracts the dashboards in the Generic Module under Packs/ThreatIntel/GenericModules/genericmodule-ThreatIntel.json and creates a new module file without changing the original file. All the new files are created in Packs/ThreatIntel.

Last updated

Was this helpful?