Fix CI: replace actions/checkout with manual git clone
Some checks failed
Build & Release / build-linux-x86_64 (push) Failing after 24s
CI / test (push) Successful in 1m6s
Build & Release / build-linux-aarch64 (push) Failing after 28s
Build & Release / build-linux-armv7 (push) Failing after 32s
Build & Release / release (push) Has been skipped

The act runner executes actions/checkout inside the job container,
but that action is a Node.js script and rust:1.86-slim has no node.
Use plain git clone instead.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Siavash Sameni
2026-03-31 14:10:15 +04:00
parent f97ee1387f
commit 99a751fa28
2 changed files with 109 additions and 100 deletions

View File

@@ -11,19 +11,29 @@ env:
jobs:
test:
runs-on: ubuntu-latest
runs_on: ubuntu-latest
container:
image: rust:1.86-slim
steps:
- uses: actions/checkout@v4
- name: Install git
run: apt-get update && apt-get install -y --no-install-recommends git
- name: Checkout
run: |
git config --global --add safe.directory '*'
git clone --depth 1 --branch ${GITHUB_REF_NAME:-main} ${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}.git .
working_directory: /workspace
- name: Run tests
run: cargo test -- --test-threads=1
working_directory: /workspace
- name: Build release
run: cargo build --release
working_directory: /workspace
- name: Check binary
run: |
ls -lh target/release/btest
target/release/btest --version
working_directory: /workspace