rust/library/compiler-builtins/ci/update-musl.sh
Trevor Gross 83aea652e4 ci: Use a mirror for musl
We pretty often get at least one job failed because of failure to pull
the musl git repo. Switch this to the unofficial mirror [1] which should
be more reliable.

Link: https://github.com/kraj/musl [1]
2025-07-24 04:06:56 -05:00

16 lines
339 B
Bash
Executable File

#!/bin/sh
# Download musl to a repository for `musl-math-sys`
set -eux
url=https://github.com/kraj/musl.git
ref=c47ad25ea3b484e10326f933e927c0bc8cded3da
dst=crates/musl-math-sys/musl
if ! [ -d "$dst" ]; then
git clone "$url" "$dst" --single-branch --depth=1000
fi
git -C "$dst" fetch "$url" --depth=1
git -C "$dst" checkout "$ref"