mirror of
https://github.com/comit-network/xmr-btc-swap.git
synced 2025-04-20 07:56:05 -04:00
Add command to generate bitcoin deposit address
This commit is contained in:
parent
23cbee842f
commit
7e10c5e7c3
@ -52,6 +52,10 @@ pub enum Command {
|
||||
Resume(Resume),
|
||||
Cancel(Cancel),
|
||||
Refund(Refund),
|
||||
Deposit {
|
||||
#[structopt(flatten)]
|
||||
config: Config,
|
||||
},
|
||||
}
|
||||
|
||||
#[derive(structopt::StructOpt, Debug)]
|
||||
|
@ -331,6 +331,18 @@ async fn main() -> Result<()> {
|
||||
)
|
||||
.await??;
|
||||
}
|
||||
Command::Deposit { config } => {
|
||||
let (bitcoin_wallet, _) = init_wallets(
|
||||
config.path,
|
||||
bitcoin_network,
|
||||
&wallet_data_dir,
|
||||
monero_network,
|
||||
seed,
|
||||
)
|
||||
.await?;
|
||||
let address = bitcoin_wallet.new_address().await?;
|
||||
info!("Deposit bitcoin here: {}", address);
|
||||
}
|
||||
};
|
||||
|
||||
Ok(())
|
||||
|
Loading…
x
Reference in New Issue
Block a user