mirror of
https://github.com/imjasonh/krust
synced 2026-07-06 22:12:32 +00:00
Fix zigbuild detection: use cargo zigbuild --help
cargo-zigbuild --version doesn't work reliably in all PATH configs. Use cargo zigbuild --help instead, which uses cargo's subcommand discovery to find the cargo-zigbuild binary. Also verify zigbuild actually works in CI after installation. https://claude.ai/code/session_01EcsZDNeWn56wFqryb4Wq7r
This commit is contained in:
parent
eb296df008
commit
508913e07e
2 changed files with 4 additions and 3 deletions
3
.github/workflows/ci.yml
vendored
3
.github/workflows/ci.yml
vendored
|
|
@ -51,7 +51,8 @@ jobs:
|
|||
# ziglang pip package installs as python-zig, symlink to zig for cargo-zigbuild
|
||||
sudo ln -sf "$(which python-zig)" /usr/local/bin/zig
|
||||
zig version
|
||||
command -v cargo-zigbuild || cargo install cargo-zigbuild
|
||||
cargo-zigbuild --version 2>/dev/null || cargo install cargo-zigbuild
|
||||
cargo-zigbuild --version
|
||||
|
||||
- run: make check-fmt
|
||||
- run: make lint
|
||||
|
|
|
|||
|
|
@ -32,8 +32,8 @@ impl RustBuilder {
|
|||
|
||||
/// Check that cargo-zigbuild is available, or bail with install instructions.
|
||||
fn require_zigbuild() -> Result<()> {
|
||||
let available = Command::new("cargo-zigbuild")
|
||||
.arg("--version")
|
||||
let available = Command::new("cargo")
|
||||
.args(["zigbuild", "--help"])
|
||||
.stdout(std::process::Stdio::null())
|
||||
.stderr(std::process::Stdio::null())
|
||||
.status()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue