diff --git a/.github/actions/build_target/action.yaml b/.github/actions/build_target/action.yaml index a49d9ee0..51503d9a 100644 --- a/.github/actions/build_target/action.yaml +++ b/.github/actions/build_target/action.yaml @@ -23,7 +23,7 @@ runs: - name: Compile binary shell: bash - run: cargo build -q --all --profile=${{ inputs.profile }} --target ${{ inputs.target }} + run: cargo build -q --workspace ${{ contains(inputs.target, 'musl') && '--exclude context-js --exclude context-py' || '' }} --profile=${{ inputs.profile }} --target ${{ inputs.target }} - name: Create binary with debug info shell: bash diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index c343958f..aac405ab 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -44,11 +44,11 @@ jobs: uses: taiki-e/install-action@nextest - name: Run tests - run: cargo nextest run --profile=ci + run: cargo nextest run --workspace ${{ contains(matrix.target, 'musl') && '--exclude context-js --exclude context-py' || '' }} --profile=ci - name: Build ${{ matrix.target }} target if: "!cancelled()" - run: cargo build -q --all --release --target ${{ matrix.target }} + run: cargo build -q --workspace ${{ contains(matrix.target, 'musl') && '--exclude context-js --exclude context-py' || '' }} --release --target ${{ matrix.target }} - name: Upload results using action from ${{ matrix.target }} env: @@ -88,7 +88,7 @@ jobs: run: curl -LsSf https://get.nexte.st/latest/linux-arm | tar zxf - -C ${CARGO_HOME:-~/.cargo}/bin - name: Run tests - run: cargo nextest run --profile=ci + run: cargo nextest run --workspace ${{ contains(matrix.target, 'musl') && '--exclude context-js --exclude context-py' || '' }} --profile=ci - name: Build ${{ matrix.target }} target uses: ./.github/actions/build_target diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ebc3c39e..a51dc450 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -78,7 +78,7 @@ jobs: - name: Build ${{ matrix.target }} target if: "!cancelled()" - run: cargo build -q --all --profile=release-with-debug --target ${{ matrix.target }} + run: cargo build -q --workspace ${{ contains(matrix.target, 'musl') && '--exclude context-js --exclude context-py' || '' }} --profile=release-with-debug --target ${{ matrix.target }} - name: Strip debug info run: strip target/${{ matrix.target }}/release-with-debug/trunk-analytics-cli