cargo-bullet-0.1.2 is not a library.
bullet
bullet is a project boilerplate generator
install
linux/unix/mac
- install rust: curl https://sh.rustup.rs -sSf | sh
- install bullet: cargo install cargo-bullet
- check version: cargo bullet --version
windows
- install rust: following rust-lang
- install bullet: cargo install cargo-bullet
- check version: cargo bullet --version
install from source
- install rust
- git clone https://github.com/thegenius/bullet.git
- cd bullet
- cargo build --release
- ./target/release/bullet.exe --version
usage
cargo bullet --config=<config_file> --template=<template_dir> --out=<out_dir>
config file example: build.toml
= "example"
= "test"
[]
= "This is my content"
project structure example: templates/structure/structure.toml
project_structure = [
["{{ context.group }}.{{context.project }}", "hello.txt", "hello.txt.tmpl"]
]
project template example: templates/template/hello.txt.tmpl
hello {{ context.project }} {{ context.ext.my_content }}
generate the project
cargo bullet -c build.toml -t templates -o output
idea
when we develop a project, we always write many boilerplate code, config and etc. so to save your life time.
- create a project template.
- config the project with yaml or json or toml.
- generate the project
supported templates
java spring
./release/bullet_win_0.1.exe -c release/build_example.toml -t release/templates/spring_java -o output