From 0cbb0a806378ab4278a12476219b5f82d225db18 Mon Sep 17 00:00:00 2001 From: Mahmoud Mazouz Date: Wed, 3 Apr 2024 11:38:15 +0200 Subject: [PATCH] fix: Incorrect cross usage predicate --- dist/build-crates-debian-main.js | 2 +- dist/build-crates-standalone-main.js | 2 +- dist/bump-crates-main.js | 2 +- dist/publish-crates-cargo-main.js | 2 +- dist/publish-crates-debian-main.js | 2 +- dist/publish-crates-eclipse-main.js | 2 +- dist/publish-crates-github-main.js | 2 +- dist/publish-crates-homebrew-main.js | 2 +- src/cargo.ts | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/dist/build-crates-debian-main.js b/dist/build-crates-debian-main.js index 33c7554..fb5197d 100644 --- a/dist/build-crates-debian-main.js +++ b/dist/build-crates-debian-main.js @@ -128405,7 +128405,7 @@ async function build(path, target) { const crossContents = await fs.readFile(join(path, "Cross.toml"), "utf-8"); const crossManifest = toml.parse(crossContents); sh(`rustup target add ${target}`, { cwd: path }); - const command = target in crossManifest ? ["cross"] : ["cargo"]; + const command = target in crossManifest.target ? ["cross"] : ["cargo"]; command.push("build", "--release", "--bins", "--lib", "--target", target); sh(command.join(" "), { cwd: path }); } diff --git a/dist/build-crates-standalone-main.js b/dist/build-crates-standalone-main.js index d0faf62..e897769 100644 --- a/dist/build-crates-standalone-main.js +++ b/dist/build-crates-standalone-main.js @@ -128404,7 +128404,7 @@ async function build(path, target) { const crossContents = await promises_.readFile((0,external_path_.join)(path, "Cross.toml"), "utf-8"); const crossManifest = parse(crossContents); command_sh(`rustup target add ${target}`, { cwd: path }); - const command = target in crossManifest ? ["cross"] : ["cargo"]; + const command = target in crossManifest.target ? ["cross"] : ["cargo"]; command.push("build", "--release", "--bins", "--lib", "--target", target); command_sh(command.join(" "), { cwd: path }); } diff --git a/dist/bump-crates-main.js b/dist/bump-crates-main.js index 17374fc..36da28e 100644 --- a/dist/bump-crates-main.js +++ b/dist/bump-crates-main.js @@ -82263,7 +82263,7 @@ async function build(path, target) { const crossContents = await fs.readFile(join(path, "Cross.toml"), "utf-8"); const crossManifest = toml.parse(crossContents); sh(`rustup target add ${target}`, { cwd: path }); - const command = target in crossManifest ? ["cross"] : ["cargo"]; + const command = target in crossManifest.target ? ["cross"] : ["cargo"]; command.push("build", "--release", "--bins", "--lib", "--target", target); sh(command.join(" "), { cwd: path }); } diff --git a/dist/publish-crates-cargo-main.js b/dist/publish-crates-cargo-main.js index 2c4ad88..5f3a16b 100644 --- a/dist/publish-crates-cargo-main.js +++ b/dist/publish-crates-cargo-main.js @@ -82263,7 +82263,7 @@ async function build(path, target) { const crossContents = await fs.readFile(join(path, "Cross.toml"), "utf-8"); const crossManifest = toml.parse(crossContents); sh(`rustup target add ${target}`, { cwd: path }); - const command = target in crossManifest ? ["cross"] : ["cargo"]; + const command = target in crossManifest.target ? ["cross"] : ["cargo"]; command.push("build", "--release", "--bins", "--lib", "--target", target); sh(command.join(" "), { cwd: path }); } diff --git a/dist/publish-crates-debian-main.js b/dist/publish-crates-debian-main.js index f050c18..401eb60 100644 --- a/dist/publish-crates-debian-main.js +++ b/dist/publish-crates-debian-main.js @@ -128427,7 +128427,7 @@ async function build(path, target) { const crossContents = await fs.readFile(join(path, "Cross.toml"), "utf-8"); const crossManifest = toml.parse(crossContents); sh(`rustup target add ${target}`, { cwd: path }); - const command = target in crossManifest ? ["cross"] : ["cargo"]; + const command = target in crossManifest.target ? ["cross"] : ["cargo"]; command.push("build", "--release", "--bins", "--lib", "--target", target); sh(command.join(" "), { cwd: path }); } diff --git a/dist/publish-crates-eclipse-main.js b/dist/publish-crates-eclipse-main.js index 6f5dbe7..d8ea97f 100644 --- a/dist/publish-crates-eclipse-main.js +++ b/dist/publish-crates-eclipse-main.js @@ -128424,7 +128424,7 @@ async function build(path, target) { const crossContents = await fs.readFile(join(path, "Cross.toml"), "utf-8"); const crossManifest = toml.parse(crossContents); sh(`rustup target add ${target}`, { cwd: path }); - const command = target in crossManifest ? ["cross"] : ["cargo"]; + const command = target in crossManifest.target ? ["cross"] : ["cargo"]; command.push("build", "--release", "--bins", "--lib", "--target", target); sh(command.join(" "), { cwd: path }); } diff --git a/dist/publish-crates-github-main.js b/dist/publish-crates-github-main.js index ff2ab1b..d7fee1a 100644 --- a/dist/publish-crates-github-main.js +++ b/dist/publish-crates-github-main.js @@ -128405,7 +128405,7 @@ async function build(path, target) { const crossContents = await fs.readFile(join(path, "Cross.toml"), "utf-8"); const crossManifest = toml.parse(crossContents); sh(`rustup target add ${target}`, { cwd: path }); - const command = target in crossManifest ? ["cross"] : ["cargo"]; + const command = target in crossManifest.target ? ["cross"] : ["cargo"]; command.push("build", "--release", "--bins", "--lib", "--target", target); sh(command.join(" "), { cwd: path }); } diff --git a/dist/publish-crates-homebrew-main.js b/dist/publish-crates-homebrew-main.js index c9cd295..8d1d4df 100644 --- a/dist/publish-crates-homebrew-main.js +++ b/dist/publish-crates-homebrew-main.js @@ -128426,7 +128426,7 @@ async function build(path, target) { const crossContents = await fs.readFile(join(path, "Cross.toml"), "utf-8"); const crossManifest = toml.parse(crossContents); sh(`rustup target add ${target}`, { cwd: path }); - const command = target in crossManifest ? ["cross"] : ["cargo"]; + const command = target in crossManifest.target ? ["cross"] : ["cargo"]; command.push("build", "--release", "--bins", "--lib", "--target", target); sh(command.join(" "), { cwd: path }); } diff --git a/src/cargo.ts b/src/cargo.ts index 115f68b..01958d0 100644 --- a/src/cargo.ts +++ b/src/cargo.ts @@ -310,7 +310,7 @@ export async function build(path: string, target: string) { sh(`rustup target add ${target}`, { cwd: path }); - const command = target in crossManifest ? ["cross"] : ["cargo"]; + const command = target in crossManifest.target ? ["cross"] : ["cargo"]; command.push("build", "--release", "--bins", "--lib", "--target", target); sh(command.join(" "), { cwd: path }); }