Asks a few deep soul-searching questions and then creates a new rust project accordingly. Don't worry, it's mostly harmless.
Learn more about cargo generate
here.
cargo generate tonyb983/cargo-generate-template
.gitignore
- this is for the TEMPLATE, not the project created from it, it will be deleted, andgitignore
will be renamed to.gitignore
.github
- Empty folder serving as the endpoint for GH actions should the user opt-in to themcargo-generate.toml
- template-only file that will not be transferred to the newly created projectCargo.toml
- obvious, but it will be filled in with as much information as possible, as well as outlining several cool techniquesgitignore
- thegitignore
file for the newly created project, will be renamed to.gitignore
licenses
- holds all of the license files, the selected license will be moved to the root folder and the rest will be deletedoptional
- folder containing all optional features that a project can elect to usebenches/
- containscriterion
benchmarking exampleflames/
- empty folder that serves as the output directory for generated flamegraph dumpstests/
- integration test examplesvscode/
-PROJECT.code-workspace
file in case the user wants to use VSCodewf/
- holds the github workflows that will be moved to.github/workflows/
if the user elects to use themflame_example.rs
- simple example(s) showing how to measure and dump flamegraph datapuffin_example.rs
- simple example showing how to use thepuffin
crate to do profiling
post-setup.rhai
- A few post-generate commands to correctly layout the new projectpre-setup.rhai
- This script moves the files needed for any optional features that are chosenREADME.md
- The readme for the template, the document you are currently readingREADME.PROJECT.md
- A skeleton readme for the newly generated project.vscode/
- Creates acode-workspace
file to use with VSCode. Can be deleted if you plan on using a different editor/IDE
- Add support for repo hosts other than Github
- This will be a bit complicated as many of the README badges are set up through github
- Add support for more licenses
- Are there any others that should be added?
- Add option for adding tests (integration tests)
- Add option for adding benches (with criterion probably?)
- Add flamegraph generation example
- Add
puffin
profiling example? (similar to the flamegraph example) - Add option for adding examples folder?
- Add support for workspaces? (might be somewhat complex, maybe it should be a separate template?)
- Find more cool badges to pad that README file 😊