From 0eace80c9d1a4ac67c3d7051d2bc5cdb16950bc3 Mon Sep 17 00:00:00 2001 From: Chad Ostrowski <221614+chadoh@users.noreply.github.com> Date: Mon, 10 Jun 2024 16:09:41 -0400 Subject: [PATCH] fix: mark `deploy::wasm::Cmd` fields as public (#1366) * fix: mark `deploy::wasm::Cmd` fields as public This is currently unusable as a library because you either don't define these fields, or get yelled at because you try to define private fields * fix: mark `bindings::typescript::Cmd` fields as pub --- .../src/commands/contract/bindings/typescript.rs | 10 +++++----- cmd/soroban-cli/src/commands/contract/deploy/wasm.rs | 8 ++++---- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/cmd/soroban-cli/src/commands/contract/bindings/typescript.rs b/cmd/soroban-cli/src/commands/contract/bindings/typescript.rs index 1204da980..b75804d72 100644 --- a/cmd/soroban-cli/src/commands/contract/bindings/typescript.rs +++ b/cmd/soroban-cli/src/commands/contract/bindings/typescript.rs @@ -25,17 +25,17 @@ pub struct Cmd { pub wasm: Option, /// Where to place generated project #[arg(long)] - output_dir: PathBuf, + pub output_dir: PathBuf, /// Whether to overwrite output directory if it already exists #[arg(long)] - overwrite: bool, + pub overwrite: bool, /// The contract ID/address on the network #[arg(long, visible_alias = "id")] - contract_id: String, + pub contract_id: String, #[command(flatten)] - locator: locator::Args, + pub locator: locator::Args, #[command(flatten)] - network: network::Args, + pub network: network::Args, } #[derive(thiserror::Error, Debug)] diff --git a/cmd/soroban-cli/src/commands/contract/deploy/wasm.rs b/cmd/soroban-cli/src/commands/contract/deploy/wasm.rs index 0b944c78a..029aa333e 100644 --- a/cmd/soroban-cli/src/commands/contract/deploy/wasm.rs +++ b/cmd/soroban-cli/src/commands/contract/deploy/wasm.rs @@ -37,18 +37,18 @@ use crate::{ pub struct Cmd { /// WASM file to deploy #[arg(long, group = "wasm_src")] - wasm: Option, + pub wasm: Option, /// Hash of the already installed/deployed WASM file #[arg(long = "wasm-hash", conflicts_with = "wasm", group = "wasm_src")] - wasm_hash: Option, + pub wasm_hash: Option, /// Custom salt 32-byte salt for the token id #[arg( long, help_heading = HEADING_RPC, )] - salt: Option, + pub salt: Option, #[command(flatten)] - config: config::Args, + pub config: config::Args, #[command(flatten)] pub fee: crate::fee::Args, #[arg(long, short = 'i', default_value = "false")]