GoodData Command-line Interface

The GoodData Command-line Interface (CLI) lets you easily sync your local environment with the server.

This is done using the following commands:

  • clone Downloads analytical objects from the workspace and saves them to your local environment.
  • deploy Replaces the target workspace with your local analytical objects.

To install the CLI, run npm i -g @gooddata/code-cli.

Options

OptionDescription
-h or --helpDisplay the usage information.
-v or --versionShow GoodData CLI version.

Commands

CommandDescription
initInitialize a local GoodData environment.
cloneClone analytical objects from the workspace.
deployDeploy analytical objects to GoodData.
validateValidate local environment.
helpDisplay the usage information.

clone

Clone analytical objects from the workspace.

clone uses information from the configuration file to connect to GoodData.

Example of use:

gd clone -f

options

OptionDescription
-l,--log-level <level>Log verbosity (choices: “error”, “warn”, “info”, “debug”, default: “info”)
-p or --profile <profileName>Profile to use
-f or --forceOverwrites source_dir if it exists. All files in that folder will be erased.
-h, --helpDisplay the usage information.

init

Initialize a local GoodData environment.

Creates gooddata.yaml configuration file. Also creates .env to store environmental variables and .gitignore, if you’d like to store your analytics in Version Control System (like git).

Example of use:

gd init

options

OptionDescription
-l,--log-level <level>Log verbosity (choices: “error”, “warn”, “info”, “debug”, default: “info”)
-h, --helpDisplay the usage information.

deploy

Deploys all local analytical objects to the workspace defined in the profile. The operation replaces objects in the target workspace.

Example of use:

gd deploy --profile production

options

OptionDescription
-l,--log-level <level>Log verbosity (choices: “error”, “warn”, “info”, “debug”, default: “info”)
-p or --profile <profileName>Profile to use
--no-validateSkips validation before deployment
-h, --helpDisplay the usage information.

validate

Validates analytical objects defined in .yaml files for syntactic errors.

Example of use:

gd validate

options

OptionDescription
-l,--log-level <level>Log verbosity (choices: “error”, “warn”, “info”, “debug”, default: “info”)
-p or --profile <profileName>Profile to use
-h, --helpDisplay the usage information.

help

Display the usage information.

Example of use:

gd help

options

No options; use one of the listed commands.