Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Scaffolding

The bevy new command lets you easily scaffold a new Bevy project using a custom template or the default minimal template, bevy_new_minimal. Internally, bevy new relies on cargo generate and will ask to install it for you if you don't already have it. Templates are just GitHub repositories and can be specified with the --template / -t flag.

Usage

If the template is omitted, bevy_new_minimal will be chosen:

bevy new my-project

Other built-in templates from TheBevyFlock will be usable via its shortcut form. For example, -t 2d will use the template bevy_new_2d:

bevy new -t 2d my-project

To use any other template on Github, provide the full URL:

bevy new my-project --template https://github.com/TheBevyFlock/bevy_new_2d

To pass additional arguments to cargo-generate, put them after --:

# Don't prompt the user and use the default values for variables.
bevy new -t 2d my-project -- --silent