DanielKeep / cargo-script

Cargo script subcommand
Other
729 stars 37 forks source link

Support custom templates #46

Closed DanielKeep closed 7 years ago

DanielKeep commented 7 years ago

Allow users to specify their own templates for hosting --expr scripts. i.e.:

cargo script -tdisplay --expr 42

With something akin to this in $CARGO_HOME/script-templates/display.rs.template:

%p fn main() { println!("{:?}", %b); }
DanielKeep commented 7 years ago

Implemented in 0.2.5.