Skip to content
This repository has been archived by the owner on Dec 11, 2024. It is now read-only.

Commit

Permalink
Merge pull request #13 from golemcloud/customizable-stubgen-command
Browse files Browse the repository at this point in the history
Expose the stubgen command/args publicly
  • Loading branch information
vigoo authored Mar 3, 2024
2 parents b4c4a7e + 9d44bce commit 94861ab
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
10 changes: 7 additions & 3 deletions wasm-rpc-stubgen/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -288,12 +288,16 @@ pub fn compose(args: ComposeArgs) -> anyhow::Result<()> {
Ok(())
}

pub fn initialize_workspace(args: InitializeWorkspaceArgs) -> anyhow::Result<()> {
pub fn initialize_workspace(
args: InitializeWorkspaceArgs,
stubgen_command: &str,
stubgen_prefix: &[&str],
) -> anyhow::Result<()> {
make::initialize_workspace(
&args.targets,
&args.callers,
args.wasm_rpc_path_override,
"golem-wasm-rpc-stubgen",
&[],
stubgen_command,
stubgen_prefix,
)
}
6 changes: 5 additions & 1 deletion wasm-rpc-stubgen/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,11 @@ async fn main() {
let _ = render_error(compose(compose_args));
}
Command::InitializeWorkspace(init_workspace_args) => {
let _ = render_error(initialize_workspace(init_workspace_args));
let _ = render_error(initialize_workspace(
init_workspace_args,
"golem-wasm-rpc-stubgen",
&[],
));
}
}
}
Expand Down

0 comments on commit 94861ab

Please sign in to comment.