Crates.io | truck-rs |
lib.rs | truck-rs |
version | 0.2.5 |
source | src |
created_at | 2022-04-24 11:33:39.779673 |
updated_at | 2022-04-24 20:43:24.047825 |
description | Supercharges cargo |
homepage | |
repository | https://github.com/useless-rs/truck |
max_upload_size | |
id | 573075 |
size | 14,359 |
For Supercharging cargo
It is based on this reddit comment. It improves cargo build speed.
Both do the same thing, but Truck also comes with mold support and uses lesser number of lines for achieving the purpose.
This is created for newbies for their first PR. This project is barebones and can be extended. (Like adding colored output or fixing mistakes in the Readme.md file and if the PR makes sense, I will push it). It is only for educational purpose.
It creates a .cargo/config.toml file and rust-toolchain.toml file which replaces default linker with lld(Linux) or zld(MacOS) and mold(linux) and ccache with sccache. (See the reddit comment for more details)
brew install michaeleisel/zld/zld
sudo pacman -Syu lld
)sudo pacman -Syu mold
)cargo install truck-rs
Make sure $CARGO_HOME/bin is in path
truck [TRUCK FLAGS]
Creates optimisations on existing projectstruck new my_file [TRUCK FLAGS]
Similar to cargo new myfile but with truck optimisationstruck init my_file [TRUCK FLAGS]
Similar to cargo init but with truck optimisationsRun cargo build or run to see the magic
MIT
If you find anything that can impove Rust's performance, please add it in optimisations.md