Edit Page

CLI commands reference


In their daily work, most Ember developers use only a small number of CLI commands. See the Basic use section for a guide to common CLI commands and options.

This page shows a full list of Ember CLI commands and options. You can view this information at anytime by typing the following

ember --help

Note: As Ember CLI is constantly evolving it's best to use this command to view the latest help for the version of Ember CLI you are currently using.

Commands from ember-cli

Available commands from Ember CLI in alphabetical order:

Command Description
ember addon Generates a new folder structure for building
ember asset-sizes Shows the sizes of your asset files.
ember build Builds your app and places it into the output
ember destroy Destroys code generated by `generate` command.
ember generate Generates new code from blueprints.
ember help Outputs the usage instructions for all commands.
ember init Creates a new ember-cli project in the current folder.
ember install Installs an ember-cli addon from npm.
ember serve Builds and serves your app, rebuilding on file changes.
ember test Runs your app's test suite
ember version outputs ember-cli version

ember addon

Generates a new folder structure for building

ember addon <addon-name> <options...>
  Generates a new folder structure for building
   an addon, complete with test harness.
  --dry-run (Boolean) (Default: false)
    aliases: -d
  --verbose (Boolean) (Default: false)
    aliases: -v
  --blueprint (String) (Default: addon)
    aliases: -b <value>
  --skip-npm (Boolean) (Default: false)
    aliases: -sn
  --skip-bower (Boolean) (Default: false)
    aliases: -sb
  --skip-git (Boolean) (Default: false)
    aliases: -sg
  --yarn (Boolean)
  --directory (String)
    aliases: -dir <value>
  --lang (String) Sets the base human language of the addon's own test application via index.html

ember asset-sizes

Shows the sizes of your asset files.

ember asset-sizes <options...>
  Shows the sizes of your asset files.
  --output-path (Path) (Default: dist/)
    aliases: -o <value>
  --json (Boolean) (Default: false)

ember build

Builds your app and places it into the output

ember build <options...>
  Builds your app and places it into the output
   path (dist/ by default).
  aliases: b
  --environment (String) (Default: development)
   Possible values are "development", "production", and "test".
    aliases: -e <value>, -dev
     (--environment=development), -prod
      (--environment=production)
  --output-path (Path) (Default: dist/)
    aliases: -o <value>
  --watch (Boolean) (Default: false)
    aliases: -w
  --watcher (String)
  --suppress-sizes (Boolean) (Default: false)

ember destroy

Destroys code generated by generate command.

ember destroy <blueprint> <options...>
  Destroys code generated by `generate` command.
  aliases: d
  --dry-run (Boolean) (Default: false)
    aliases: -d
  --verbose (Boolean) (Default: false)
    aliases: -v
  --pod (Boolean) (Default: false)
    aliases: -p, -pods
  --classic (Boolean) (Default: false)
    aliases: -c
  --dummy (Boolean) (Default: false)
    aliases: -dum, -id
  --in-repo-addon (String) (Default: null)
    aliases: --in-repo <value>, -ir <value>
  --in (String) (Default: null) Runs a blueprint 
  against an in repo addon. A path is expected,
   relative to the
    root of the project.

ember generate

Generates new code from blueprints.

ember generate <blueprint> <options...>
  Generates new code from blueprints.
  aliases: g
  --dry-run (Boolean) (Default: false)
    aliases: -d
  --verbose (Boolean) (Default: false)
    aliases: -v
  --pod (Boolean) (Default: false)
    aliases: -p, -pods
  --classic (Boolean) (Default: false)
    aliases: -c
  --dummy (Boolean) (Default: false)
    aliases: -dum, -id
  --in-repo-addon (String) (Default: null)
    aliases: --in-repo <value>, -ir <value>
  --in (String) (Default: null) Runs a blueprint
   against an in repo addon. A path is expected,
    relative to the root of the project.

Available blueprints from ember-source

ember generate acceptance-test

Generates an acceptance test for a feature.

ember generate acceptance-test <name>
  Generates an acceptance test for a feature.

ember generate component

Generates a component.

ember generate component <name> <options...>
  Generates a component.
  --path (String) (Default: components)
    aliases: --no-path (--path="")
  --component-class (@ember/component, @glimmer/component, @ember/component/template-only, "") (Default: --no-component-class)
    aliases: -cc (--component-class=@ember/component), -gc (--component-class=@glimmer/component), -tc (--component-class=@ember/component/template-only), -nc (--component-class=""), --no-component-class (--component-class=""), --with-component-class (--component-class=@glimmer/component)
  --component-structure (flat, nested, classic) (Default: flat)
    aliases: -fs (--component-structure=flat), -ns (--component-structure=nested), -cs (--component-structure=classic)

ember generate component-addon

Generates a component.

ember generate component-addon <name>
  Generates a component.

ember generate component-class

Generates a component class.

ember generate component-class <name> <options...>
  Generates a component class.
  --path (String) (Default: components)
    aliases: --no-path (--path="")
  --component-class (@ember/component, @glimmer/component, @ember/component/template-only) (Default: @glimmer/component)
    aliases: -cc (--component-class=@ember/component), -gc (--component-class=@glimmer/component), -tc (--component-class=@ember/component/template-only)
  --component-structure (flat, nested, classic) (Default: flat)
    aliases: -fs (--component-structure=flat), -ns (--component-structure=nested), -cs (--component-structure=classic)

ember generate component-class-addon

Generates a component class.

ember generate component-class-addon <name>
  Generates a component class.

ember generate component-test

Generates a component integration or unit test.

ember generate component-test <name> <options...>
  Generates a component integration or unit test.
  --test-type (integration, unit) (Default: integration)
    aliases: -i (--test-type=integration), -u (--test-type=unit), --integration (--test-type=integration), -unit (--test-type=unit)

ember generate controller

Generates a controller.

ember generate controller <name>
  Generates a controller.

ember generate controller-test

Generates a controller unit test.

ember generate controller-test <name>
  Generates a controller unit test.

ember generate helper

Generates a helper function.

ember generate helper <name>
  Generates a helper function.

ember generate helper-addon

Generates an import wrapper.

ember generate helper-addon <name>
  Generates an import wrapper.

ember generate helper-test

Generates a helper integration test or a unit test.

ember generate helper-test <name> <options...>
  Generates a helper integration test or a unit test.
  --test-type (integration, unit) (Default: integration)
    aliases: -i (--test-type=integration), -u (--test-type=unit), --integration (--test-type=integration), -unit (--test-type=unit)

ember generate initializer

Generates an initializer.

ember generate initializer <name>
  Generates an initializer.

ember generate initializer-addon

Generates an import wrapper.

ember generate initializer-addon <name>
  Generates an import wrapper.

ember generate initializer-test

Generates an initializer unit test.

ember generate initializer-test <name>
  Generates an initializer unit test.

ember generate instance-initializer

Generates an instance initializer.

ember generate instance-initializer <name>
  Generates an instance initializer.

ember generate instance-initializer-addon

Generates an import wrapper.

ember generate instance-initializer-addon <name>
  Generates an import wrapper.

ember generate instance-initializer-test

Generates an instance initializer unit test.

ember generate instance-initializer-test <name>
  Generates an instance initializer unit test.

ember generate mixin

Generates a mixin.

ember generate mixin <name>
  Generates a mixin.

ember generate mixin-test

Generates a mixin unit test.

ember generate mixin-test <name>
  Generates a mixin unit test.

ember generate route

Generates a route and a template, and registers the route with the router.

ember generate route <name> <options...>
  Generates a route and a template, and registers the route with the router.
  --path (String) (Default: "")
  --skip-router (Boolean) (Default: false)
  --reset-namespace (Boolean)

ember generate route-addon

Generates import wrappers for a route and its template.

ember generate route-addon <name>
  Generates import wrappers for a route and its template.

ember generate route-test

Generates a route unit test.

ember generate route-test <name> <options...>
  Generates a route unit test.
  --reset-namespace (Boolean)

ember generate service

Generates a service.

ember generate service <name>
  Generates a service.

ember generate service-test

Generates a service unit test.

ember generate service-test <name>
  Generates a service unit test.

ember generate template

Generates a template.

ember generate template <name>
  Generates a template.

ember generate util

Generates a simple utility module/function.

ember generate util <name>
  Generates a simple utility module/function.

ember generate util-test

Generates a util unit test.

ember generate util-test <name>
  Generates a util unit test.

Available blueprints from ember-data

ember generate adapter

Generates an ember-data adapter.

ember generate adapter <name> <options...>
  Generates an ember-data adapter.
  --base-class (String)

ember generate adapter-test

Generates an ember-data adapter unit test

ember generate adapter-test <name>
  Generates an ember-data adapter unit test

ember generate model

Generates an ember-data model.

ember generate model <name> <attr:type>
  Generates an ember-data model.

ember generate model-test

Generates a model unit test.

ember generate model-test <name>
  Generates a model unit test.

ember generate serializer

Generates an ember-data serializer.

ember generate serializer <name> <options...>
  Generates an ember-data serializer.
  --base-class (String)

ember generate serializer-test

Generates a serializer unit test.

ember generate serializer-test <name>
  Generates a serializer unit test.

ember generate transform

Generates an ember-data value transform.

ember generate transform <name>
  Generates an ember-data value transform.

ember generate transform-test

Generates a transform unit test.

ember generate transform-test <name>
  Generates a transform unit test.

Available blueprints from ember-cli

ember generate addon

The default blueprint for ember-cli addons.

ember generate addon <name>
  The default blueprint for ember-cli addons.

ember generate addon-import

Generates an import wrapper.

ember generate addon-import <name>
  Generates an import wrapper.

ember generate app

The default blueprint for ember-cli projects.

ember generate app <name>
  The default blueprint for ember-cli projects.

ember generate blueprint

Generates a blueprint and definition.

ember generate blueprint <name>
  Generates a blueprint and definition.

ember generate http-mock

Generates a mock api endpoint in /api prefix.

ember generate http-mock <endpoint-path>
  Generates a mock api endpoint in /api prefix.

ember generate http-proxy

Generates a relative proxy to another server.

ember generate http-proxy <local-path> <remote-url>
  Generates a relative proxy to another server.

ember generate in-repo-addon

The blueprint for addon in repo ember-cli addons.

ember generate in-repo-addon <name>
  The blueprint for addon in repo ember-cli addons.

ember generate lib

Generates a lib directory for in-repo addons.

ember generate lib <name>
  Generates a lib directory for in-repo addons.

ember generate server

Generates a server directory for mocks and proxies.

ember generate server <name>
  Generates a server directory for mocks and proxies.

ember generate vendor-shim

Generates an ES6 module shim for global libraries.

ember generate vendor-shim <name>
  Generates an ES6 module shim for global libraries.

ember help

Outputs the usage instructions for all commands

ember help <command-name (Default: all)> <options...>
  Outputs the usage instructions for all commands
   or the provided command
  aliases: h, --help, -h
  --verbose (Boolean) (Default: false)
    aliases: -v
  --json (Boolean) (Default: false)

ember init

Creates a new ember-cli project in the current folder.

ember init <glob-pattern> <options...>
  Creates a new ember-cli project in the current folder.
  --dry-run (Boolean) (Default: false)
    aliases: -d
  --verbose (Boolean) (Default: false)
    aliases: -v
  --blueprint (String)
    aliases: -b <value>
  --skip-npm (Boolean) (Default: false)
    aliases: -sn
  --skip-bower (Boolean) (Default: false)
    aliases: -sb
  --welcome (Boolean) (Default: true) Installs and
   uses {{ember-welcome-page}}. Use --no-welcome to
    skip it.
  --yarn (Boolean)
  --name (String) (Default: "")
    aliases: -n <value>
  --lang (String) Sets the base human language of the application via index.html

ember install

Installs an ember-cli addon from npm.

ember install <addon-name> <options...>
  Installs an ember-cli addon from npm.
  aliases: i
  --save (Boolean) (Default: false)
    aliases: -S
  --save-dev (Boolean) (Default: true)
    aliases: -D
  --save-exact (Boolean) (Default: false)
    aliases: -E, --exact
  --yarn (Boolean) Use --yarn to enforce yarn 
  usage, or --no-yarn to enforce npm

ember new

Creates a new directory and runs ember init in it.

ember new <app-name> <options...>
  Creates a new directory and runs ember init in it.
  --dry-run (Boolean) (Default: false)
    aliases: -d
  --verbose (Boolean) (Default: false)
    aliases: -v
  --blueprint (String) (Default: app)
    aliases: -b <value>
  --skip-npm (Boolean) (Default: false)
    aliases: -sn
  --skip-bower (Boolean) (Default: false)
    aliases: -sb
  --skip-git (Boolean) (Default: false)
    aliases: -sg
  --welcome (Boolean) (Default: true) Installs and
   uses {{ember-welcome-page}}. Use --no-welcome to
    skip it.
  --yarn (Boolean)
  --directory (String)
    aliases: -dir <value>
  --lang (String) Sets the base human language of the application via index.html

ember serve

Builds and serves your app, rebuilding on file changes.

ember serve <options...>
  Builds and serves your app, rebuilding on file changes.
  aliases: server, s
  --port (Number) (Default: 4200) To use a port different
   than 4200. Pass 0 to automatically pick an available
    port.
    aliases: -p <value>
  --host (String) Listens on all interfaces by default
    aliases: -H <value>
  --proxy (String)
    aliases: -pr <value>, -pxy <value>
  --proxy-in-timeout (Number) (Default: 120000) When
   using --proxy: timeout (in ms) for incoming requests
    aliases: -pit <value>
  --proxy-out-timeout (Number) (Default: 0) When using
   --proxy: timeout (in ms) for outgoing requests
    aliases: -pot <value>
  --secure-proxy (Boolean) (Default: true) Set to false 
  to proxy self-signed SSL certificates
    aliases: -spr
  --transparent-proxy (Boolean) (Default: true) Set to false 
  to omit x-forwarded-* headers when proxying
    aliases: --transp
  --watcher (String) (Default: events)
    aliases: -w <value>
  --live-reload (Boolean) (Default: true)
    aliases: -lr
  --live-reload-host (String) Defaults to host
    aliases: -lrh <value>
  --live-reload-base-url (String) Defaults to baseURL
    aliases: -lrbu <value>
  --live-reload-port (Number) 
  Defaults to same port as ember app
    aliases: -lrp <value>
  --live-reload-prefix (String) (Default: _lr) 
  Default to _lr
    aliases: --lrprefix <value>
  --environment (String) (Default: development) P
  ossible values are "development", "production", and "test".
    aliases: -e <value>, -dev (--environment=development),
     -prod (--environment=production)
  --output-path (Path) (Default: dist/)
    aliases: -op <value>, -out <value>
  --ssl (Boolean) (Default: false) Set to true to 
  configure Ember CLI to serve using SSL.
  --ssl-key (String) (Default: ssl/server.key) 
  Specify the private key to use for SSL.
  --ssl-cert (String) (Default: ssl/server.crt) 
  Specify the certificate to use for SSL.
  --path (Path) Reuse an existing build at given path.

ember test

Runs your app's test suite.

ember test <options...>
  Runs your app's test suite.
  aliases: t
  --environment (String) (Default: test) Possible values 
  are "development", "production", and "test".
    aliases: -e <value>
  --config-file (String)
    aliases: -c <value>, -cf <value>
  --server (Boolean) (Default: false)
    aliases: -s
  --host (String)
    aliases: -H <value>
  --test-port (Number) (Default: 7357) The test port
   to use when running tests. Pass 0 to automatically
    pick an available port
    aliases: -tp <value>
  --filter (String) A string to filter tests to run
    aliases: -f <value>
  --module (String) The name of a test module to run
    aliases: -m <value>
  --watcher (String) (Default: events)
    aliases: -w <value>
  --launch (String) (Default: false) A comma 
  separated list of browsers to launch for tests.
  --reporter (String) Test reporter to use
  [tap|dot|xunit] (default: tap)
    aliases: -r <value>
  --silent (Boolean) (Default: false) Suppress
   any output except for the test report
  --ssl (Boolean) (Default: false) Set to true
   to configure testem to run the test suite
    using SSL.
  --ssl-key (String) (Default: ssl/server.key) 
  Specify the private key to use for SSL.
  --ssl-cert (String) (Default: ssl/server.crt)
   Specify the certificate to use for SSL.
  --testem-debug (String) File to write a 
  debug log from testem
  --test-page (String) Test page to invoke
  --path (Path) Reuse an existing build at
   given path.
  --query (String) A query string to append 
  to the test page URL.
  --output-path (Path)
    aliases: -o <value>

ember version

outputs ember-cli version

ember version <options...>
  outputs ember-cli version
  aliases: v, --version, -v
  --verbose (Boolean) (Default: false)

Commands from @ember/optional-features

Command Description
ember feature Prints the USAGE.
ember feature:list PriList all available features.
ember feature:enable Enable feature.
ember feature:disable Disable feature.

ember feature

Prints the USAGE.

Available commands from @ember/optional-features:
ember feature
  Prints the USAGE.

ember feature:list

List all available features.

ember feature:list
  List all available features.

ember feature:enable

Enable feature.

ember feature:enable <feature-name> <options...>
  Enable feature.
  --run-codemod (Boolean) run any associated
   codemods without prompting

ember feature:disable

Disable feature.

ember feature:disable <feature-name> <options...>
  Disable feature.
  --run-codemod (Boolean) run any associated
   codemods without prompting

Commands from ember-cli-template-lint

Command Description
ember template-lint:print-failing Get current list of all failing templates.

ember template-lint:print-failing

Get current list of all failing templates.

Available commands from ember-cli-template-lint:
ember template-lint:print-failing
  Get current list of all failing templates. 
  This can be used to update the `pending` 
  listing in `.template-lintrc.js`.