From 240140dfe6b64eaa15ee93e93b67de9c9d384137 Mon Sep 17 00:00:00 2001 From: 0xCypher <168461073+0xcypher02@users.noreply.github.com> Date: Thu, 1 Aug 2024 13:42:33 -0400 Subject: [PATCH] spl-token-cli: support compute price + limit with native tokens --- token/cli/src/command.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/token/cli/src/command.rs b/token/cli/src/command.rs index 1faf086127a..300febb36b2 100644 --- a/token/cli/src/command.rs +++ b/token/cli/src/command.rs @@ -195,6 +195,14 @@ fn native_token_client_from_config( config.fee_payer()?.clone(), ); + let token = token.with_compute_unit_limit(config.compute_unit_limit.clone()); + + let token = if let Some(compute_unit_price) = config.compute_unit_price { + token.with_compute_unit_price(compute_unit_price) + } else { + token + }; + if let (Some(nonce_account), Some(nonce_authority), Some(nonce_blockhash)) = ( config.nonce_account, &config.nonce_authority,