Bevy-template-rs
Here are a few cargo-generate
templates for use when creating bevy applications.
Templates
Game
This is a template for starting a new game.
- Binary
- Latest (0.6) Bevy version, or GitHub main version (as a patch), are both supported.
- The template can optionally setup the project for using "fast compiles" as described in The Bevy Book.
- Basic GitHub workflow for building/testing the resulting project
- Code example for doing integration tests
- VSCode launch configuration for executable/unit-tests and integration test
- VSCode tasks
lib-plugin
A simple template for creating a plugin with Bevy.
- Library
- Code example for doing integration tests
- VSCode launch configuration for debugging unit and integration tests
- VSCode tasks
lib-assets
A library for hosting embedded assets by utilizing the Bevy-Embasset crate.
- Library
- Assets folder for assets that should be embedded
- VSCode launch configuration for debugging unit-tests
- VSCode tasks
Usage
cargo generate taurr/bevy-template-rs
Requirements
cargo-generate must be installed. The easiest way to do this is:
cargo install cargo-generate
Tips'n'tricks
If the template is used on a regular basis, cargo-generate allows to setup favorite templates and default variables.
To do this, open or create the file $CARGO_HOME/cargo-generate.toml
, insert this:
[favorites.bevy]
path = "taurr/bevy-template-rs"
After this, the template can be expanded using a simple:
cargo generate bevy