config(cargo): enable strip and lto for release builds

main
sudo pacman -Syu 2024-08-17 00:59:04 +07:00
parent ccbb7449ea
commit 83950e9dde
3 changed files with 9 additions and 1 deletions

4
data/cargo/config.toml Normal file
View File

@ -0,0 +1,4 @@
# https://github.com/johnthagen/min-sized-rust
[profile.release]
strip = true
lto = true

View File

@ -121,3 +121,7 @@ external = "~/.config/typos/typos.toml"
[[apps.daktilo.paths]] [[apps.daktilo.paths]]
internal = "data/daktilo/daktilo.toml" internal = "data/daktilo/daktilo.toml"
external = "~/.config/daktilo/daktilo.toml" external = "~/.config/daktilo/daktilo.toml"
[[apps.cargo.paths]]
internal = "data/cargo/config.toml"
external = "~/.cargo/config.toml"

View File

@ -454,7 +454,7 @@ require("lazy").setup({
lua = { "stylua" }, lua = { "stylua" },
markdown = { "deno_fmt" }, markdown = { "deno_fmt" },
proto = { "buf" }, proto = { "buf" },
python = { "ruff_format", "ruff_organize_imports" }, python = { "ruff_format" },
sh = { "shfmt" }, sh = { "shfmt" },
sql = { "sqlfluff" }, sql = { "sqlfluff" },
toml = { "trim_whitespace", "taplo" }, toml = { "trim_whitespace", "taplo" },