{"id":26570484,"url":"https://github.com/TheBevyFlock/bevy_cli","last_synced_at":"2025-03-22T22:01:47.131Z","repository":{"id":255038716,"uuid":"848293016","full_name":"TheBevyFlock/bevy_cli","owner":"TheBevyFlock","description":"A Bevy CLI tool and linter.","archived":false,"fork":false,"pushed_at":"2025-03-19T17:49:09.000Z","size":621,"stargazers_count":98,"open_issues_count":97,"forks_count":13,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-03-20T11:06:53.758Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://thebevyflock.github.io/bevy_cli/","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TheBevyFlock.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-27T13:52:33.000Z","updated_at":"2025-03-20T09:27:32.000Z","dependencies_parsed_at":"2024-10-23T16:31:54.804Z","dependency_job_id":"af410166-304f-4ccb-b9fe-0e465e14f930","html_url":"https://github.com/TheBevyFlock/bevy_cli","commit_stats":{"total_commits":68,"total_committers":8,"mean_commits":8.5,"dds":"0.36764705882352944","last_synced_commit":"cbaf5959cc2fd1343a5152518ec2ba0cba0cd52f"},"previous_names":["thebevyflock/bevy_cli"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheBevyFlock%2Fbevy_cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheBevyFlock%2Fbevy_cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheBevyFlock%2Fbevy_cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheBevyFlock%2Fbevy_cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TheBevyFlock","download_url":"https://codeload.github.com/TheBevyFlock/bevy_cli/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245025981,"owners_count":20549071,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-03-22T22:01:07.515Z","updated_at":"2025-03-22T22:01:47.094Z","avatar_url":"https://github.com/TheBevyFlock.png","language":"Rust","readme":"# Bevy CLI\n\nA prototype [Bevy] CLI tool intended to streamline common tasks when working on projects. Please see the [initial scope document] and [original issue] for history and motivation. The CLI's current features include:\n\n- Project generation from a template\n- [A custom, Bevy-specific linter](bevy_lint/README.md)\n- Out-of-the-box support for building and running your Bevy app in the browser\n\nIf you need assistance or want to help, reach out to the [`bevy_cli` working group channel] in the [Bevy Discord].\n\n[Bevy]: https://bevyengine.org\n[initial scope document]: https://hackmd.io/cCHAfbtaSviU_MDnbNHKxg\n[original issue]: https://github.com/bevyengine/bevy/issues/436\n[`bevy_cli` working group channel]: https://discord.com/channels/691052431525675048/1278871953721262090\n[Bevy Discord]: https://discord.gg/bevy\n\n## Installation\n\nAt this point, the CLI is not published as a package yet and needs to be installed via git:\n\n```sh\ncargo install --git https://github.com/TheBevyFlock/bevy_cli --locked bevy_cli\n```\n\n## Logging\n\nThe default logging level for the CLI is set to `info`. To change the log level set the `BEVY_LOG` environment variable.\n\n```sh\nexport BEVY_LOG=trace\n```\n\n## Bevy web apps\n\nThe CLI makes it easy to build and run web apps made with Bevy, using `bevy build web` and `bevy run web`.\nIt takes care of compiling the app to Wasm, creating JavaScript bindings and serving it on a local web server to test it out.\nNecessary tools will also be installed automatically.\n\n\u003e [!NOTE]\n\u003e\n\u003e The arguments you know from `cargo` (like `--release`) must be placed before the `web` subcommand, while the web-specific options (like `--open`) must be placed afterwards, e.g.\n\u003e\n\u003e ```sh\n\u003e bevy run --release web --open\n\u003e ```\n\n### Running in the browser\n\nUse the `bevy run web` command to run your app in the browser.\nThe app will be automatically served on a local web server, use the `--open` flag to automatically open it in the browser.\n\nThe server will provide a default `index.html` serving as entrypoint for your app.\nIt features a loading screen and some other utilities.\nIf you want to customize it, simply create a `web/index.html` file to override the default behavior.\nOther files in the `web` folder will also be included in your application.\n\n### Creating web bundles\n\nTo deploy your app on a web server, it's often necessary to bundle the binary, assets and web files into a single folder.\nUsing `bevy build web --bundle`, the CLI can create this bundle for you automatically.\nIt will be available in the `target/bevy_web` folder, see the command's output for the full file path.\n\n### Compilation profiles\n\nWeb apps have different needs than native builds when it comes to compilation.\nFor example, binary size is a lot more important for web apps, as it has a big influence on the loading times.\n\nThe Bevy CLI provides custom `web` and `web-release` compilation profiles, which are optimized for web apps.\nThey are used by default for the web sub-commands (depending on the `--release` flag).\n\nThe profiles can be customized as usual in `Cargo.toml`:\n\n```toml\n[profile.web-release]\ninherits = \"release\"\nopt-level = \"z\"\n```\n\nAlternatively, you can change the profile entirely, e.g. `bevy run --profile=foo web`.\n\n### Usage in CI\n\nThe CLI may include interactive prompts if parts of the required tooling is not installed on the system.\nThese prompts will break your pipeline if they are triggered in CI.\n\nTo avoid this problem, use the `--yes` flag to automatically confirm the prompts:\n\n```sh\nbevy build --yes web\n```\n\n## Bevy scaffolding\n\nThe `bevy new` command lets you easily scaffold a new Bevy project using a custom template or a [minimal template provided by Bevy](https://github.com/TheBevyFlock/bevy_new_minimal).\nTemplates are just GitHub repositories and can be specified with the `-t` flag.\n\n### Usage\n\nIf the template is omitted, the [default minimal template](https://github.com/TheBevyFlock/bevy_new_minimal) will be chosen.\n\n```sh\nbevy new my-project\n```\n\nTo use a specific template, provide the full GitHub URL\n\n```sh\nbevy new my-project -t https://github.com/TheBevyFlock/bevy_new_2d\n```\n\nAdditionally, any repo prefixed with `bevy_new_` from the [TheBevyFlock](https://github.com/TheBevyFlock) will be usable via its shortcut form i.e. `-t 2d` will use the template [bevy_new_2d](https://github.com/TheBevyFlock/bevy_new_2d).\n\n```sh\nbevy new my-project -t 2d\n```\n\n## Linter\n\nThe CLI has 1st-party support for `bevy_lint`, the static analysis tool that checks over your code (similar to Clippy!). It must be installed first using the [installation guide], but then you can run the linter with the `lint` subcommand:\n\n```sh\nbevy lint\n```\n\nThis command uses the same arguments as `cargo check`:\n\n```sh\nbevy lint --workspace --all-features\n```\n\nYou can view a full list of supported options with:\n\n```sh\nbevy lint -- --help\n```\n\n[installation guide]: https://thebevyflock.github.io/bevy_cli/bevy_lint/index.html#installation\n\n## License\n\nThe Bevy CLI is licensed under either of\n\n- Apache License, Version 2.0 ([`LICENSE-APACHE`](LICENSE-APACHE) or \u003chttp://www.apache.org/licenses/LICENSE-2.0\u003e)\n- MIT license ([`LICENSE-MIT`](LICENSE-MIT) or \u003chttp://opensource.org/licenses/MIT\u003e)\n\nat your option.\n\n## Contributing\n\nPlease see [`CONTRIBUTING.md`](CONTRIBUTING.md) for more information!\n\nUnless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.\n","funding_links":[],"categories":["Code Organization"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTheBevyFlock%2Fbevy_cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FTheBevyFlock%2Fbevy_cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTheBevyFlock%2Fbevy_cli/lists"}