From d6ea7bbbc4f533b0a6fd51cf4e231d7159142a5c Mon Sep 17 00:00:00 2001 From: Stefan Kreutz Date: Sat, 5 Aug 2023 18:11:01 +0200 Subject: [PATCH] Improve 'cargo tree' check (#1200) The '! cargo tree -i openssl-sys' command ignores when 'cargo tree' fails for other reasons than not depending on the openssl-sys crate. This commit changes the command to propagate such a failure. --- .github/workflows/ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5cbc2bd..8a8ad5d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -118,9 +118,7 @@ jobs: - uses: dtolnay/rust-toolchain@stable - uses: Swatinem/rust-cache@v2 - name: Check that rustls-tls feature doesn't depend on OpenSSL - shell: bash - run: | - ! cargo tree --package lychee --no-default-features --features rustls-tls -i openssl-sys + run: test -z "$( cargo tree --package lychee --no-default-features --features rustls-tls --prefix none | sed -n '/^openssl-sys /p' )" - name: Run cargo check with default features uses: actions-rs/cargo@v1 with: