From 0deb0142257976783b121a2012a67f93dc588adb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=94=D0=B0=D0=BC=D1=98=D0=B0=D0=BD=20=D0=93=D0=B5=D0=BE?= =?UTF-8?q?=D1=80=D0=B3=D0=B8=D0=B5=D0=B2=D1=81=D0=BA=D0=B8?= Date: Fri, 9 Sep 2022 14:41:09 +0200 Subject: [PATCH] cargo.toml profiles support strip = true so use that in the release profile, no need to run the explicit strip command now also `codegen-units = 1` for more optimizations --- .github/workflows/release.yml | 8 +++----- Cargo.toml | 2 ++ 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a7fcdf1..8f3efd4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -25,15 +25,13 @@ jobs: asset_name: http-server-$tag-windows.zip zipcmd: 7z a -tzip steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Build project run: cargo build --release --locked - - name: Post-build release preparation - run: | - strip target/release/${{ matrix.artifact_name }} - ${{ matrix.zipcmd}} release.zip target/release/${{ matrix.artifact_name }} + - name: make release.zip + run: ${{ matrix.zipcmd}} release.zip target/release/${{ matrix.artifact_name }} - name: Upload binary to release uses: svenstaro/upload-release-action@v2 diff --git a/Cargo.toml b/Cargo.toml index a49c31c..f946a01 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,3 +23,5 @@ v_htmlescape = "0.14.1" opt-level = 'z' lto = true panic = 'abort' +strip = true +codegen-units = 1