diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c333aa03af..9abcdd2343 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -71,7 +71,7 @@ jobs: - name: Do release build shell: bash - run: $BUILD_CMD build --release --target ${{ matrix.target }} + run: CARGO_TARGET_X86_64_UNKNOWN_LINUX_MUSL_RUSTFLAGs='-C link-arg=-s' $BUILD_CMD build --release --target ${{ matrix.target }} - name: Move binary to root of checkout shell: bash diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml deleted file mode 100644 index 7ed92e23da..0000000000 --- a/.github/workflows/test.yml +++ /dev/null @@ -1,88 +0,0 @@ -on: [push, pull_request] - -name: Continuous integration - -jobs: - build: - name: Test ${{ matrix.job.target }} - runs-on: ${{ matrix.job.os }} - strategy: - fail-fast: false - matrix: - job: - - { target: x86_64-unknown-linux-gnu, os: ubuntu-20.04 } - - { target: x86_64-apple-darwin, os: macos-latest } - - { target: x86_64-pc-windows-gnu, os: windows-latest } - - { target: x86_64-unknown-linux-musl, os: ubuntu-20.04, use-cross: true } - - { target: aarch64-unknown-linux-gnu, os: ubuntu-20.04, use-cross: true } - - { target: aarch64-apple-darwin, os: macos-latest, use-cross: true } - env: - BUILD_CMD: cargo - - steps: - - name: Checkout source code - uses: actions/checkout@v3 - - - name: Install Rust toolchain - uses: dtolnay/rust-toolchain@1.59.0 - with: - targets: ${{ matrix.job.target }} - - - name: Install cross - if: matrix.job.use-cross - uses: taiki-e/install-action@v2 - with: - tool: cross - - - name: Overwrite build command env variable - if: matrix.job.use-cross - shell: bash - run: echo "BUILD_CMD=cross" >> $GITHUB_ENV - - - name: Test - shell: bash - run: $BUILD_CMD test - - test_mime_db: - name: Test with MIME database - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v3 - - uses: dtolnay/rust-toolchain@1.59.0 - # This runs tests that rely on the MIME database being present. - - run: cargo test -- --ignored - - test_linux_latest_stable: - name: Test Linux (latest stable Rust) - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v3 - - uses: dtolnay/rust-toolchain@stable - - run: cargo +stable test - - regression_test: - name: Output Regression Test - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v3 - - uses: dtolnay/rust-toolchain@1.59.0 - - name: Generate output for all sample files - run: ./sample_files/compare_all.sh - - name: Verify output is unchanged - run: diff -C2 sample_files/compare.result sample_files/compare.expected - - package: - name: Check Linux Packaging - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v3 - - uses: dtolnay/rust-toolchain@1.59.0 - - run: cargo package --allow-dirty - - fmt: - name: Rustfmt - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v3 - - uses: dtolnay/rust-toolchain@1.59.0 - - run: cargo fmt --all -- --check