From 7cb789ca033620279e8f20958b7ba4af24ecaea2 Mon Sep 17 00:00:00 2001 From: Muhammad Nauman Raza Date: Sun, 19 May 2024 12:19:26 +0100 Subject: [PATCH] cargo: file size optimisations --- Cargo.toml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Cargo.toml b/Cargo.toml index 6f6699b..7639b7e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -6,3 +6,10 @@ edition = "2021" [dependencies] owo-colors = "4.0.0" pinger = "1.1.1" + +[profile.release] +strip = true # Strip debug symbols +opt-level = "z" # Optimise for size +lto = true # Enable link type optimisation +codegen-units = 1 # Reduce parallel code generation units +panic = "abort" # Abort on panic!