mirror of
https://github.com/ouch-org/ouch.git
synced 2025-06-06 19:45:29 +00:00
chore: use new Cargo profile in CI for shorter compilation
new profile is called `fast` and it's not as fast as `release`, but should be fast enough for CI and compiles faster
This commit is contained in:
parent
162dfbd29f
commit
97b4608693
@ -126,17 +126,18 @@ jobs:
|
|||||||
# there's no way to run tests for ARM64 Windows for now
|
# there's no way to run tests for ARM64 Windows for now
|
||||||
if: matrix.target != 'aarch64-pc-windows-msvc'
|
if: matrix.target != 'aarch64-pc-windows-msvc'
|
||||||
run: |
|
run: |
|
||||||
${{ env.CARGO }} +stable test --release --target ${{ matrix.target }} $EXTRA_CARGO_FLAGS
|
${{ env.CARGO }} +stable test --profile fast --target ${{ matrix.target }} $EXTRA_CARGO_FLAGS
|
||||||
|
|
||||||
- name: Build artifacts (binary and completions)
|
- name: Build release artifacts (binary and completions)
|
||||||
|
if: ${{ inputs.upload_artifacts }}
|
||||||
run: |
|
run: |
|
||||||
${{ env.CARGO }} +stable build --release --target ${{ matrix.target }} $EXTRA_CARGO_FLAGS
|
${{ env.CARGO }} +stable build --release --target ${{ matrix.target }} $EXTRA_CARGO_FLAGS
|
||||||
env:
|
env:
|
||||||
OUCH_ARTIFACTS_FOLDER: artifacts
|
OUCH_ARTIFACTS_FOLDER: artifacts
|
||||||
|
|
||||||
- name: Upload artifacts
|
- name: Upload release artifacts
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
if: ${{ inputs.upload_artifacts }}
|
if: ${{ inputs.upload_artifacts }}
|
||||||
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: ouch-${{ matrix.target }}-${{ steps.concat-features.outputs.FEATURES }}
|
name: ouch-${{ matrix.target }}-${{ steps.concat-features.outputs.FEATURES }}
|
||||||
path: |
|
path: |
|
||||||
|
@ -73,8 +73,17 @@ default = ["use_zlib", "use_zstd_thin", "unrar"]
|
|||||||
use_zlib = ["flate2/zlib", "gzp/deflate_zlib", "zip/deflate-zlib"]
|
use_zlib = ["flate2/zlib", "gzp/deflate_zlib", "zip/deflate-zlib"]
|
||||||
use_zstd_thin = ["zstd/thin"]
|
use_zstd_thin = ["zstd/thin"]
|
||||||
|
|
||||||
|
# For generating binaries for releases
|
||||||
[profile.release]
|
[profile.release]
|
||||||
lto = true
|
lto = true
|
||||||
codegen-units = 1
|
codegen-units = 1
|
||||||
opt-level = 3
|
opt-level = 3
|
||||||
strip = true
|
strip = true
|
||||||
|
|
||||||
|
# When we need a fast binary that compiles slightly faster `release` (useful for CI)
|
||||||
|
[profile.fast]
|
||||||
|
inherits = "release"
|
||||||
|
lto = false
|
||||||
|
opt-level = 2
|
||||||
|
incremental = true
|
||||||
|
codegen-units = 16
|
||||||
|
Loading…
x
Reference in New Issue
Block a user