Skip to main content

init

The moon init [dest] command will initialize moon into a repository and scaffold config files by creating a .moon folder. By default, moon will automatically infer the Node.js version, package manager, and potential projects based on existing files.

$ moon init

# In another directory
$ moon init ./app

The command can also be used to initialize a specific tool after moon has already been initialized. Perfect for adopting a new language into the workspace.

$ moon init --tool typescript

Arguments

  • [dest] - Destination to initialize and scaffold into. Defaults to . (current working directory).

Options

  • --force - Overwrite existing config files if they exist.
  • --tool - Individual tool to initialize and configure.
    • Accepts: node, typescript
  • --yes - Skip all prompts and use default values.