MCPcopy Create free account
hub / github.com/bytecodealliance/wstd / curl

Function curl

ci/publish.rs:431–444  ·  view source on GitHub ↗
(url: &str)

Source from the content-addressed store, hash-verified

429}
430
431fn curl(url: &str) -> Option<String> {
432 let output = cmd_output(
433 Command::new("curl")
434 .arg("--user-agent")
435 .arg("bytecodealliance/wstd auto-publish script")
436 .arg(url),
437 );
438 if !output.status.success() {
439 println!("failed to curl: {}", output.status);
440 println!("stderr: {}", String::from_utf8_lossy(&output.stderr));
441 return None;
442 }
443 Some(String::from_utf8_lossy(&output.stdout).into())
444}
445
446fn cmd_output(cmd: &mut Command) -> Output {
447 eprintln!("Running: `{:?}`", cmd);

Callers 2

publishFunction · 0.85
verify_crates_ioFunction · 0.85

Calls 1

cmd_outputFunction · 0.85

Tested by

no test coverage detected