Getting Started

Infrastructure

Creating Projects from Templates

globe create

Purpose: Creates a new Dart project based on a predefined template. This can significantly speed up the initial setup for common project types.

Usage:

globe create -t <TEMPLATE_NAME> [project-name] [flags]

Flags:

  • -t, --template: Required. The name of the template to use.
  • [project-name]: Optional. The name of your new project directory. If omitted, the template name will be used.
  • --help: Displays help information.
  • --verbose: Displays verbose output.
  • --token: Use API token for CLI Auth.

Example:

# Create a new project using the 'shelf-basic' template, named 'my-api'
globe create -t shelf-basic my-api
# Create a new project using the 'flutter-web-basic' template, using the default name
globe create -t flutter-web-basic

Workflow:

  • The CLI downloads the specified template.
  • The CLI creates a new directory with the project name (or the template name if no project name is provided).
  • The CLI initializes the project (e.g., runs pub get).