From f1c65bb1e267cf7229baf332eb690697a12559be Mon Sep 17 00:00:00 2001 From: trivernis Date: Tue, 13 Apr 2021 11:46:16 +0200 Subject: [PATCH] Tweak release build for smaller binaries Signed-off-by: trivernis --- .github/workflows/build-and-release.yml | 3 ++- Cargo.toml | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-and-release.yml b/.github/workflows/build-and-release.yml index 71aac77..f596ff4 100644 --- a/.github/workflows/build-and-release.yml +++ b/.github/workflows/build-and-release.yml @@ -20,7 +20,6 @@ jobs: uses: actions/cache@v2 with: path: | - target ~/.cargo/ key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }} restore-keys: | @@ -31,6 +30,8 @@ jobs: use-cross: false command: build args: --release --target x86_64-unknown-linux-gnu + - name: Strip symbols + run: strip target/x86_64-unknown-linux-gnu/release/tobi-rs - name: Move binaries run: mv target/x86_64-unknown-linux-gnu/release/tobi-rs target/tobi-rs-linux-x86_64 - name: Upload artifacts diff --git a/Cargo.toml b/Cargo.toml index f80aac4..38ec577 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,6 +4,9 @@ version = "0.5.2" authors = ["trivernis "] edition = "2018" +[profile.release] +panic = 'abort' + # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies]