Skip to content

Commit

Permalink
Attemt #2
Browse files Browse the repository at this point in the history
  • Loading branch information
kubaplas committed May 24, 2024
1 parent b633e90 commit 1052c53
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/actions/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,9 @@ impl BuildAction<'_> {
&contract.struct_name(),
&module_name,
self.project.is_workspace(),
contract.module_crate_name(self.project),
);

let source = paths::wasm_path_in_target(&build_contract, self.project.project_root());
let target =
paths::wasm_path_in_wasm_dir(&contract.struct_name(), &self.project.project_root());
Expand Down
3 changes: 2 additions & 1 deletion src/command.rs
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,7 @@ pub fn cargo_build_wasm_files(
contract_name: &str,
module_name: &str,
is_workspace: bool,
crate_name: String,
) {
env::set_var(ODRA_MODULE_ENV_KEY, contract_name);
let build_contract = format!("{}_build_contract", module_name);
Expand All @@ -136,7 +137,7 @@ pub fn cargo_build_wasm_files(
];
if is_workspace {
params.push("--package");
params.push(module_name);
params.push(crate_name.as_str());
}
cargo(current_dir, "build", params);
}
Expand Down

0 comments on commit 1052c53

Please sign in to comment.